Informix ESQL/C SQLDA-structure problem
Posted in 1991
Path: emory!swrinde!cs.utexas.edu!uunet!mcsun!news.funet.fi!funic!nntp.hut.fi!usenet From: vwa@cs.hut.fi Newsgroups: comp.databases Message-ID: <1991Jun26.121056.19420@nntp.hut.fi> Date: 26 Jun 91 12:10:56 GMT Sender: usenet@nntp.hut.fi (Usenet pseudouser id) Organization: Helsinki University of Technology, Finland Nntp-Posting-Host: hutcs.cs.hut.fi When storing integer information in the sqlda-structure sqlda->sqlvar[i].sqldata = malloc (SIZINT) and after that executing a prepared INSERT with that structure, I never get INTEGERS right. They are always treated as CHARS somewhere during the EXECUTE. So the result is, that they are truncated like 127 -> 0 -1 -> 255 I suppose, that the definition of the field sqldata as 'char *' in the include-file sqlda.h has something to do with this problem. Having spent desparate hours debugging... Vesa W