Subject | Re: [IB-Conversions] problem with sql2gdb |
---|---|
Author | Helen Borrie |
Post date | 2000-11-19T05:03:14Z |
At 12:51 AM 19-11-00 +0000, you wrote:
reserved words as column names, avoid the quotes when you define the
columns in your metadata.
In IB 6, double-quotes are not legal syntax for delimiting values.
In the example above, you have mixed two syntax errors on the values, if
you were trying to load this interactively. The colon markers are for
parameters - you won't be able to do it this way unless you have a client
program which will pass the parameter values dynamically. (The free
IB_WISQL tool at www.ibobjects.com lets you feed parameters into dynamic
SQL statements).
The interactive version of this statement would be:
INSERT INTO mytable (
field1,
field2,
field3 /* remove this comma ----> , <----------- */
)
VALUES (
'value1', /* if value1 is a string */
value2,
value3 /* remove this comma ----> , <----------- */
)
;
If you have made your column names case-sensitive, then you are stuck with
putting them around the field list to avoid having InterBase store them as
uppercase.
hth
Helen
All for Open and Open for All
InterBase Developer Initiative ยท http://www.interbase2000.org
___________________________________________________
>I tryed to convert my .mdb to interbase's .sql with sql2gdb but allUnless you want your column names to be case-sensitive, or you want to use
>the INSERT's I got are as abobe:
>
>INSERT INTO "mytable" (
> "field1",
> "field2",
> "field3",
>) VALUES (
> :"field1",
> :"field2",
> :"field3",
>)
>;
>
>That ist, I don't get the values but only the names preceding of ':'.
reserved words as column names, avoid the quotes when you define the
columns in your metadata.
In IB 6, double-quotes are not legal syntax for delimiting values.
In the example above, you have mixed two syntax errors on the values, if
you were trying to load this interactively. The colon markers are for
parameters - you won't be able to do it this way unless you have a client
program which will pass the parameter values dynamically. (The free
IB_WISQL tool at www.ibobjects.com lets you feed parameters into dynamic
SQL statements).
The interactive version of this statement would be:
INSERT INTO mytable (
field1,
field2,
field3 /* remove this comma ----> , <----------- */
)
VALUES (
'value1', /* if value1 is a string */
value2,
value3 /* remove this comma ----> , <----------- */
)
;
If you have made your column names case-sensitive, then you are stuck with
putting them around the field list to avoid having InterBase store them as
uppercase.
hth
Helen
All for Open and Open for All
InterBase Developer Initiative ยท http://www.interbase2000.org
___________________________________________________