× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



Scott,
Yes, please send me a copy of the working program.
I have my result colums defined in a MODS.
Regarding the bytes returned on the SQLBindCol,  I am not sure how to define 
it.  The prototype calls for a data type SQLINTEGER.  
I tried to define it as a sub field in a MODS, but am still getting the Error 
Type 10 on the SQLExtendedFetch.
 
Please send the link for the source, or an attachment to my direct email 
address at jyoung@xxxxxxxxxx
 
Thanks again for all the help.
 
Jeff Young


----- Original Message ----
From: Scott Klement <rpg400-l@xxxxxxxxxxxxxxxx>
To: RPG programming on the AS400 / iSeries <rpg400-l@xxxxxxxxxxxx>
Sent: Friday, July 21, 2006 5:13:59 PM
Subject: Re: SQL CLI problem


Hi Jeff,

Now I can set the attributes correctly (I think), but when I call the 
SQLExtendedFetch function, I get a SQ99999 message with Error Type 10. 
Error type 10 is function sequence error.

I _FINALLY_ figured out this error in my own program today (woo-hoo.)  To 
get rid of the "Function Sequence Error" you must:

a) Make sure all columns in the array are contiguous.  So if you're 
fetching 3 columns, the result array should be a MODS, array of DS, or 
overlayed array that contain only the 3 columsn you're fetching.

b) (This is what I missed) the "returned lengths" from the 6th parm on 
SQLBindCol must ALSO be defined contiguous in a separate MODS/DS Array/Ovr 
Array.

Without both of these, you'll get the SQ99999 message, with error type 10.

Let me know if you'd like to see a sample program (since I just finally 
got mine working! woohoo!)

As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:
Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

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.