Subject | RE: [IBO] Any progress yet on the IBO 4.6Bc bug with Parsing of Joins when using FB2.0? |
---|---|
Author | Adrian Wreyford |
Post date | 2006-11-17T12:01:17Z |
Thanks Jason
I ran the Test project and worked just fine.
Then I tried the following Query in code, in my application, and still
getting the error.
The following code snippet, may indicate what is causing the error:
procedure TFormAnimalInfo.AnimalLookup(Gender, sID: String);
begin
If Gender = 'M' Then
begin
FormAnimalLookup.IB_QueryLookupAnimals.Close;
FormAnimalLookup.IB_QueryLookupAnimals.SQL.Clear;
{I Took out the aliases A. and S. here, as not working with IBO 4BC
2006/11/11 AJW .. and put back to test your fix.}
FormAnimalLookup.IB_QueryLookupAnimals.SQL.Add('SELECT
A.ANIMALIDENTIFICATION, A.ANIMALNAME,');
FormAnimalLookup.IB_QueryLookupAnimals.SQL.Add('A.ANIMALREGISTRATIONNUMBER,
A.ANIMALHERDSTATUS, A.ANIMALDOB,');
FormAnimalLookup.IB_QueryLookupAnimals.SQL.Add('A.ANIMALGENDER,
A.ANIMALTAGCOLOUR, A.ANIMALID,');
FormAnimalLookup.IB_QueryLookupAnimals.SQL.Add('S.ANIMALSIRESTATUS,
S.ANIMALFIRSTSIREDATE');
FormAnimalLookup.IB_QueryLookupAnimals.SQL.Add('FROM ANIMAL A,
ANIMALACTIVESIRES S');
FormAnimalLookup.IB_QueryLookupAnimals.SQL.Add('where (A.ANIMALID =
S.ANIMALSIREID) AND');
FormAnimalLookup.IB_QueryLookupAnimals.SQL.Add('(A.ANIMALGENDER = ''' +
Gender + ''')');
FormAnimalLookup.IB_QueryLookupAnimals.SQL.Add('ORDER BY
A.ANIMALIDENTIFICATION');
FormAnimalLookup.IB_QueryLookupAnimals.Prepare;
FormAnimalLookup.IB_QueryLookupAnimals.Open;
IF sID <> '' then // Don't search if no value;
FormAnimalLookup.IB_QueryLookupAnimals.Locate('ANIMALIDENTIFICATION',sID,[])
;
End
I get error on prepare: Field ANIMALACTIVESIRES.ANIMALSIRESTATUS not found.
Regards
Adrian
_____
From: IBObjects@yahoogroups.com [mailto:IBObjects@yahoogroups.com] On Behalf
Of Jason Wharton
Sent: 16 November 2006 11:10 AM
To: IBObjects@yahoogroups.com
Subject: RE: [IBO] Any progress yet on the IBO 4.6Bc bug with Parsing of
Joins when using FB2.0?
I have the issues you presented both working fine. Let me know if you would
like to run a quick test with the latest sources. I'll send them to you
privately if you request it.
Jason Wharton
I ran the Test project and worked just fine.
Then I tried the following Query in code, in my application, and still
getting the error.
The following code snippet, may indicate what is causing the error:
procedure TFormAnimalInfo.AnimalLookup(Gender, sID: String);
begin
If Gender = 'M' Then
begin
FormAnimalLookup.IB_QueryLookupAnimals.Close;
FormAnimalLookup.IB_QueryLookupAnimals.SQL.Clear;
{I Took out the aliases A. and S. here, as not working with IBO 4BC
2006/11/11 AJW .. and put back to test your fix.}
FormAnimalLookup.IB_QueryLookupAnimals.SQL.Add('SELECT
A.ANIMALIDENTIFICATION, A.ANIMALNAME,');
FormAnimalLookup.IB_QueryLookupAnimals.SQL.Add('A.ANIMALREGISTRATIONNUMBER,
A.ANIMALHERDSTATUS, A.ANIMALDOB,');
FormAnimalLookup.IB_QueryLookupAnimals.SQL.Add('A.ANIMALGENDER,
A.ANIMALTAGCOLOUR, A.ANIMALID,');
FormAnimalLookup.IB_QueryLookupAnimals.SQL.Add('S.ANIMALSIRESTATUS,
S.ANIMALFIRSTSIREDATE');
FormAnimalLookup.IB_QueryLookupAnimals.SQL.Add('FROM ANIMAL A,
ANIMALACTIVESIRES S');
FormAnimalLookup.IB_QueryLookupAnimals.SQL.Add('where (A.ANIMALID =
S.ANIMALSIREID) AND');
FormAnimalLookup.IB_QueryLookupAnimals.SQL.Add('(A.ANIMALGENDER = ''' +
Gender + ''')');
FormAnimalLookup.IB_QueryLookupAnimals.SQL.Add('ORDER BY
A.ANIMALIDENTIFICATION');
FormAnimalLookup.IB_QueryLookupAnimals.Prepare;
FormAnimalLookup.IB_QueryLookupAnimals.Open;
IF sID <> '' then // Don't search if no value;
FormAnimalLookup.IB_QueryLookupAnimals.Locate('ANIMALIDENTIFICATION',sID,[])
;
End
I get error on prepare: Field ANIMALACTIVESIRES.ANIMALSIRESTATUS not found.
Regards
Adrian
_____
From: IBObjects@yahoogroups.com [mailto:IBObjects@yahoogroups.com] On Behalf
Of Jason Wharton
Sent: 16 November 2006 11:10 AM
To: IBObjects@yahoogroups.com
Subject: RE: [IBO] Any progress yet on the IBO 4.6Bc bug with Parsing of
Joins when using FB2.0?
I have the issues you presented both working fine. Let me know if you would
like to run a quick test with the latest sources. I'll send them to you
privately if you request it.
Jason Wharton
> -----Original Message-----[mailto:IBObjects@yahoogrou <mailto:IBObjects%40yahoogroups.com> ps.com]On
> From: IBObjects@yahoogrou <mailto:IBObjects%40yahoogroups.com> ps.com
> Behalf Of Adrian Wreyford[Non-text portions of this message have been removed]
> Sent: Friday, November 10, 2006 9:02 AM
> To: IBObjects@yahoogrou <mailto:IBObjects%40yahoogroups.com> ps.com
> Subject: [IBO] Any progress yet on the IBO 4.6Bc bug with Parsing of
> Joins when using FB2.0?
>
>
> Hi, I stumbled into this problem 16/09/2006, as per postings list.
>
>
>
> I quote Helen: "The re-implementation of joins in IBO 4.6Bc,
> to accommodate
> aliases
> in the SPB and the tighter identifier rules in Fb 2.0 is exhibiting a
> number of bugs, unfortunately. For serious development, you'll need
> to revert to 4.6B and Fb 1.5.3 until this gets resolved."
>
>
>
> Well I'm a registered user of IBO, and would just like to
> know, when I can
> get my application out, as still waiting for it to get resolved.
>
> I understand the tight schedules, just let me in on the
> progress please.
>
>
>
> Regards
>
>
>
> Adrian Wreyford