I'm using interbase database (on a linux server) and a client function to
copy a record with following sql statement:
"INSERT INTO artikel ( artnr, bezeichnung, beschreibung, suchbegriff, tpid,
ktid, lfid, gaid, dimension, gewicht, einheit_gew, ek_akt, kb_akt, vk1_akt,
vk2_akt, einheit_preis, lagerort_abk, stk_pro_pack, mindestbestand,
einheit_menge, bestellen, mwid, nennspannung, fert_zeit, geraet, rgid,
artnr_lf, makroname, bmz, herst_lfid, pflegedat, bnid) VALUES('149937',
'i-Control 7', '"Dezentrale und eigensichere Steuereinheit
gem.VDE 0108/10.89) zur Umschaltung von AV-Netz zur Batterieversorgung
Schaltleistung max:7000W Netzleiter ', 'ICONTROL', 0, 0, 0, 2, '',
0.0000000000, '', 0.0000000000, 0.0000000000, 718.9000000000, 0.0000000000,
'pro Stk', 'A/2/3/4/5', 0.0000000000, 0.0000000000, 'Stk', 1, 1.0000000000,
0.0000000000, 0.0000000000, 1, 1, '', '', '', 0, '03.07.2003', 62)"
With some records (like the one above) I get the error: "XSQLDA-Index
außerhalb des gültigen Bereichs" (XSQLDA-Index out of range)!
Has someone experience with this error statement and knows where the problem
is??
Thanks
Tom
> I'm using interbase database (on a linux server) and a client function to
> copy a record with following sql statement:
>
> "INSERT INTO artikel ( artnr, bezeichnung, beschreibung, suchbegriff, tpid,
> ktid, lfid, gaid, dimension, gewicht, einheit_gew, ek_akt, kb_akt, vk1_akt,
> vk2_akt, einheit_preis, lagerort_abk, stk_pro_pack, mindestbestand,
> einheit_menge, bestellen, mwid, nennspannung, fert_zeit, geraet, rgid,
> artnr_lf, makroname, bmz, herst_lfid, pflegedat, bnid) VALUES('149937',
> 'i-Control 7', '"Dezentrale und eigensichere Steuereinheit
Try removing the double quote from this string value
'"Dezentrale und eigensichere Steuereinheit
And let me know the result.
--
With regards,
Martijn Tonies
Database Workbench - the developer tool for InterBase & Firebird
Upscene Productions
http://www.upscene.com
thanks for answering my newsletter that fast, the
double quote seems to be the problem here, but when I
add a double quote to another record, the statement
works well. But the data were imported from an old
dbase format. Perhaps thats the problem with this record??
"Martijn Tonies" <m.tonies@upscene!nospam!.com> schrieb im Newsbeitrag
news:3f03...@newsgroups.borland.com...
"Martijn Tonies" <m.tonies@upscene!nospam!.com> wrote in message
news:3f04...@newsgroups.borland.com...
> Hi Thomas,
>
> > thanks for answering my newsletter that fast, the
> > double quote seems to be the problem here, but when I
> > add a double quote to another record, the statement
> > works well. But the data were imported from an old
> > dbase format. Perhaps thats the problem with this record??
>
> I think the problem lies in the ":" that's also in the data.
>
> There's some code from Borland inside TParams (or something)
> that checks for ":" when ParamCheck = True (see your
> component) - but doesn't do the quotes check in the
> right way. That is, a string started by ' can be ended by
> " I believe. If you have the Delphi source, you can search
> for the problem, I believe it's in DB.pas...
>
> Anyway, you can avoid the problem by setting ParamCheck
> to False, I think, or by using parameters all the way:
>
> INSERT INTO mytab (COL1, COL2) VALUES (:val1,
> :val2)
>
> And then bind the parameter values by:
>
> ParamByName(val1).AsString := '<value>;
>
> Etc...
> thanks for answering my newsletter that fast, the
> double quote seems to be the problem here, but when I
> add a double quote to another record, the statement
> works well. But the data were imported from an old
> dbase format. Perhaps thats the problem with this record??
I think the problem lies in the ":" that's also in the data.
There's some code from Borland inside TParams (or something)
that checks for ":" when ParamCheck = True (see your
component) - but doesn't do the quotes check in the
right way. That is, a string started by ' can be ended by
" I believe. If you have the Delphi source, you can search
for the problem, I believe it's in DB.pas...
Anyway, you can avoid the problem by setting ParamCheck
to False, I think, or by using parameters all the way:
INSERT INTO mytab (COL1, COL2) VALUES (:val1,
:val2)
And then bind the parameter values by:
ParamByName(val1).AsString := '<value>;
Etc...