|
-----Original Message-----
From: RPG400-L <rpg400-l-bounces@xxxxxxxxxxxxxxxxxx> On Behalf Of
dfreinkel@xxxxxxxxxxxxxxxxx
Sent: Mittwoch, 2. März 2022 22:46
To: 'RPG programming on IBM i' <rpg400-l@xxxxxxxxxxxxxxxxxx>
Subject: SQL0117 - Statement contains wrong number of values
This may be an IBM bug.
I have a service program that uses SQL for I/O.
The program is about 10 years old. I made a few changes and am now
getting the SQL0117 in areas that I made no changes to. The problem is
on INSERT statements. The number of statements is values is correct.
Here's an
example:
if Count = 0;
Exec Sql Insert into a4g_cm1/CMOBJ01P
(src_Library, Src_File, Src_member, Src_type,
Checked_out_in_library, Checked_out_in_File,
Checked_out_In_User,
current_Task, Reference)
Values (:Src_lib, :Src_File, :Src_member,
:Src_Type, :To_Library, :To_file,
:UsrPrf, :Task_ID, :reference);
Else;
Exec Sql Update a4g_cm1/CMOBJ01P
Set Current_Task = :Task_ID,
Checked_Out_In_Library = :To_Library,
Checked_Out_In_File = :To_File,
Checked_Out_In_User = :USRPRF,
Reference = :Reference,
Date = Current TimeStamp
where Src_Library = :Src_LIb and
Src_File = :Src_File and
Src_Member = :Src_Member and
Src_Type = :Src_Type;
ENDIF;
The error is reported for this line.
Anyone have this problem and how did you resolve it?
This is on a v7.3 system.
TIA
Darryl Freinkel
A4G
Telephone: 770.321.8562 Mobile: 678.355.8562
--
This is the RPG programming on IBM i (RPG400-L) mailing list To post a
message email: RPG400-L@xxxxxxxxxxxxxxxxxx To subscribe, unsubscribe,
or change list options,
visit: https://lists.midrange.com/mailman/listinfo/rpg400-l
or email: RPG400-L-request@xxxxxxxxxxxxxxxxxx
Before posting, please take a moment to review the archives at
https://archive.midrange.com/rpg400-l.
Please contact support@xxxxxxxxxxxxxxxxxxxx for any subscription
related questions.
Help support midrange.com by shopping at amazon.com with our affiliate link:
https://amazon.midrange.com
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].
Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.