Subject | [IBO] Re: ISC_ERROR 335544652 multiple rows in singleton select |
---|---|
Author | w1n9man |
Post date | 2004-11-01T22:49:26Z |
--- In IBObjects@yahoogroups.com, "Jason Wharton" <jwharton@i...> wrote:
Once again sorry,
The second definition at the bottom is the output from the tables
metadata - I forgot to annotate as such.
To replicate the problem do the following;
Use a TIBODatabase and TIBOTable and a button
Set the TIBOTable component to look at the "Working" table and the
TIBODatabase to look at the database.
Place two or more records in the table, with a unique UID (1,2 etc
will suffice), put values into Start(Time) and Ondate(Date), leaving
Finish as null.
Place this code in the onclick event handler for the button
TIBOTable1->Active = true;
TLocateOptions Opts;
TIBOTable1->Locate("UID", 1, Opts); // <- Error should fire here
TIBOTable1->FieldByName("FINISH")->AsDateTime = Now();
TIBOTable1->Post();
Compile and click the button.
That should do it.
If you need any more let me know.
Cheers
Trevor
> For some reason the table "WORKING" was defined twice in your script.were us
> Please take the cut down version you gave us and verify it as if you
> and provide easy to follow instructions to see the error you are having.Jason,
> I'm actually trying to see what you are doing.
>
> Jason Wharton
Once again sorry,
The second definition at the bottom is the output from the tables
metadata - I forgot to annotate as such.
To replicate the problem do the following;
Use a TIBODatabase and TIBOTable and a button
Set the TIBOTable component to look at the "Working" table and the
TIBODatabase to look at the database.
Place two or more records in the table, with a unique UID (1,2 etc
will suffice), put values into Start(Time) and Ondate(Date), leaving
Finish as null.
Place this code in the onclick event handler for the button
TIBOTable1->Active = true;
TLocateOptions Opts;
TIBOTable1->Locate("UID", 1, Opts); // <- Error should fire here
TIBOTable1->FieldByName("FINISH")->AsDateTime = Now();
TIBOTable1->Post();
Compile and click the button.
That should do it.
If you need any more let me know.
Cheers
Trevor