From: vasudev123 on
Dear All,

Currently we are using DB2 Version 9.1. We are trying to
compile a embedded SQL C++ application but db2 precompiler ( prep )
throws this error "48 SQL4020N The 'long' host variable "*" is not
valid. Use 'sqlint32' instead" so we overcame this error by passing
'LONGERROR NO' to db2 prep option.

On program execution the result from a database column is not
retrieved correctly to a long host variable. Always long host variable
value show zero. The solution of renaming long to sqlint32 datatype is
not strategic since there is a huge codebase which makes this solution
highly impractical.

I hereby request you please let me know if there is a resolution for
this issue ( any Compiler or linker option )

Environment details:-

Solaris 5.10 64bit
IBM DB2 Version 9.1

Thanks,
Vasu