Kbase 13997: Testing return code (SQLCODE) from C program (HLI/C)
Autor |
  Progress Software Corporation - Progress |
Acesso |
  Público |
Publicação |
  10/05/1998 |
|
Testing return code (SQLCODE) from C program (HLI/C)
Many customers reach the call center stating that their HLI/C program
doesn't return anything or they get the SQLCODE value returned to them
and don't know what to do.
As a general rule, if you want more information about the errors
(if there were any), you may want to modify your C program so that it
prints any generated error messages if there were errors:
EXEC SQL SELECT st\-desc INTO :my_desc FROM state where st = "TX";
if( SQLCODE < 0)
{
printf("SQLCODE=%ld\n",SQLCODE);
while ((msg = sqlgetmsg()) != (char *) 0)
printf("%s\n",msg);
}
Progress Software Technical Support Note # 13997