Page 1 of 1

TLiteTable DetailFields = Unrecognized Token ':' Errors

Posted: Wed 02 Nov 2016 17:02
by Bob Boyd
I have been unable to create a master - detail table relationship when the field names contain spaces. I used the selection dialog to create the table link using the 'Sequence ID' fields which automatically fills both the MasterFields and DetailFields properties for the linked detail table. When the linked table is activated an error is generated indicating - unrecognized token: ":" and the table can only be activated if the MasterFields or DetailFields property is cleared which breaks the one to many relationship display I need for the form grid. The debugger error indicates an exception class ESQLiteError with the same message.

I have enabled the QuoteNames property for each of the tables, is there something I'm missing about creating a master detail link?

Code: Select all

  With SequenceLiteTable do
  begin
    Close;
    Connection := WC6SourceLite;
    Options.StrictUpdate := False;
    Options.QuoteNames := True;
    TableName := 'WSequence';
    stKey := '"Sequence ID"';
    IndexFieldNames := stKey;
    SetOrderBy(stKey);
    Open;
  end;
  With WSeqnAtchLiteTable do
  begin
    Close;
    Connection := WC6SourceLite;
    Options.StrictUpdate := False;
    Options.QuoteNames := True;
    TableName := 'WSeqnAtch';
    stKey := '"Sequence ID"; Attachment';
    IndexFieldNames := stKey;
    MasterSource := SequenceDS;
//    MasterFields := 'Sequence ID';
//    DetailFields := 'Sequence ID';
    MasterFields := '"Sequence ID"';
    DetailFields := '"Sequence ID"';
    Open;
  end;

Re: TLiteTable DetailFields = Unrecognized Token ':' Errors

Posted: Fri 04 Nov 2016 09:39
by MaximG
We have reproduced the bug according to your description. We are investigating the behavior of LiteDAC when using quoted fields name and we will inform you about the results in the near future.

Re: TLiteTable DetailFields = Unrecognized Token ':' Errors

Posted: Fri 04 Nov 2016 15:03
by Bob Boyd
Thanks for the reply and confirmation of the bug. Creating the master-detail links for the form grids is crucial for our application. I just reached the milestone of importing the Absolute database records into the SQLite database using the LiteDAC table component but I need to verify the record details using the index links. I am going to attempt to verify the MasterFields and DetailFields can be linked after I restructure the tables to remove the space in the index field names however that field renaming solution for all tables would be a big setback for this project.

Re: TLiteTable DetailFields = Unrecognized Token ':' Errors

Posted: Fri 11 Nov 2016 05:55
by Bob Boyd
Has there been any progress on this issue? It has been a week now and it has delayed the conversion of numerous forms in our application. This is definitely a show stopper for using the LiteDAC components. Its hard to believe that a SQL database with spaces in index field names has never been used before I tried to convert this project. Am I the only person using the TLiteTable component?

Re: TLiteTable DetailFields = Unrecognized Token ':' Errors

Posted: Fri 11 Nov 2016 07:37
by MaximG
We will study the issue and inform you about the results soon

Re: TLiteTable DetailFields = Unrecognized Token ':' Errors

Posted: Fri 11 Nov 2016 15:36
by Bob Boyd
Soon? Last week it was the 'near future', would you please provide an estimate of when there may be a fix. I have to report back to the client and we have to make a decision about continuing development with this component. I have 2 months invested in this SQL conversion already and need to demonstrate a working UI by the end of the year. I reached the milestone two weeks ago of importing records from the AbsDB into the SQLite DB and hit this blocker. Right now the only forms I can display are with tables that are not linked, the main form has to display the Attachment and Archives records for 5 different test types linked to an Equipment ID using the master - detail link. If this is not going to be fixed quickly, I may have to reattempt using the Rx built in FireDAC components.

Re: TLiteTable DetailFields = Unrecognized Token ':' Errors

Posted: Wed 16 Nov 2016 10:07
by MaximG
Thank you for your information. We fixed the bug related to using quotes in fields names. Fixing will be included into the next LiteDAC build. We are planning to release this build early next week.

Re: TLiteTable DetailFields = Unrecognized Token ':' Errors

Posted: Wed 16 Nov 2016 14:25
by Bob Boyd
Fantastic news!

Re: TLiteTable DetailFields = Unrecognized Token ':' Errors

Posted: Tue 22 Nov 2016 17:15
by Bob Boyd
I installed V2.7.27 today and it has solved the problem so I now have the master-detail links working for the grid displays. Thank you for this fix that was crucial for our application!

Re: TLiteTable DetailFields = Unrecognized Token ':' Errors

Posted: Wed 23 Nov 2016 11:51
by MaximG
We were glad to help you. Please don't hesitate to contact us with questions concerning LiteDAC usage.