Data is wrong for char [message #416073] |
Thu, 30 July 2009 06:15 |
suaiko9999
Messages: 2 Registered: July 2009
|
Junior Member |
|
|
hi...i have a code as below, when i run the .pc file, i cannot get the account number that i wanted.
strcpy(connectstr, dbid);
EXEC SQL CONNECT :connectstr;
int ret=1;
EXEC SQL EXECUTE
BEGIN
SELECT COUNT(1) ACCOUNT_NO
INTO : S_ACCOUNT_NO
FROM account_T
WHERE ACCOUNT_NO = 1000000073;
END;
END-EXEC;
/*-------------- end PL/SQL block -----------------*/
printf("Number\n");
printf("%d\n", sqlstmt.arr, ACCOUNT_NO);
exit(0);
any idea on this? thanks alot.
|
|
|
|
Re: Data is wrong for char [message #416085 is a reply to message #416083] |
Thu, 30 July 2009 07:20 |
suaiko9999
Messages: 2 Registered: July 2009
|
Junior Member |
|
|
hi sorry...i'm new in Pro*C. the code already compile and basically in my main() i need to retrieve the data for the account number 1000000073 and there's data in the table. There is no error, but basically i got the wrong data. The output results should be 1000000073.
|
|
|
|