What doing to Error while duplicate record when field name starting with numeric

Discussion of open issues, suggestions and bugs regarding IBDAC (InterBase Data Access Components) for Delphi, C++Builder, Lazarus (and FPC)
Post Reply
atrungroi
Posts: 1
Joined: Mon 16 Jul 2018 10:26

What doing to Error while duplicate record when field name starting with numeric

Post by atrungroi » Mon 16 Jul 2018 10:29

I got an SQL error -104 Token Unknow at line x char xx 404.

My Code are:-

procedure CopyButtonClick(Sender: TObject; AButtonIndex: Integer);
var
aField : Variant ;
i : Integer ;
begin
with qryWht do
begin
// create a variant Array
aField:= VarArrayCreate([0,Fieldcount-1],VarVariant);
// read values into the array
for i:= 1 to (Fieldcount-1) do
aField:= fields.Value ;
Append;
// put array values into new the record
for i:= 1 to (Fieldcount-1) do
fields.Value:= aField;
Post;
end;
end;

The cause of this came from one of my fieldname starting with 404 and after correct it, an error gone.

This will not happen for normal update (Insert, change data value, Post).

I used IBDAC 1.10.13 with D7

ViktorV
Devart Team
Posts: 3168
Joined: Wed 30 Jul 2014 07:16

Re: What doing to Error while duplicate record when field name starting with numeric

Post by ViktorV » Mon 16 Jul 2018 14:43

In order for us to be able to give you a detailed answer, we need a sample demonstrating the behavior you mentioned. Therefore, please, compose a full sample demonstrating the described behavior and send it to us using the contact form https://devart.com/company/contactform.html including database objects creating scripts.

Post Reply