Lynn(dot)Tilby(at)asu(dot)edu writes:
> fprintf(DBG_OUT,"sqlcode = %f\n", sqlca.sqlcode); \
%f would be appropriate for printing a float or double value. But
sqlcode is integral (long to be specific). You probably want %ld here.
The other uses of %f are wrong too.
regards, tom lane