Translating with DrWatson… this can take a few seconds the first time.
This is a genuine, complex translation. DrWatson protects commands, error codes, and log output while naturally translating the surrounding text. It’s translated once and saved.
Sally Woolrich — — source: Informix-list mailing list archive (1991-1998)
In article <3qvqg7$2mq@bennett.eng.umd.edu>
mkerry@Glue.umd.edu "Michael Kerry" writes:
<snip>
> $table = 'mydata';
> $insert = &isql_open(<<EOI) || die $isql_code;
> insert into $table(inv_data) values(?)
> EOI
>
> # insert it
> #
>
> &isql_execute($insert, (@ary)) || die $isql_code;
>
>
> That last line is bad, giving the error
> "-1213 Character to numeric conversion error"
I suspect the problem is that the correct syntax is as follows:
table sally
(
charfield char( 1 ),
numfield integer
);
insert into sally values( 'X', 1 );
e.g. you need quotes around values to be inserted into
CHAR, and possible DATE and DATETIME type columns.
Easiest to put them round all values as it doesn't stop an insert
into a numeric type column.
--
============================================================================
Sally Woolrich | This mail contains my personal
sally@excelsis.demon.co.uk | views not those of my employer!
============================================================================
We use strictly necessary cookies to make this site work. With your
consent we’d also use optional cookies for analytics and marketing. You can accept all,
reject all, or choose. Read our Cookie Policy.