Subject | Re: Source code fix - DISTINCT count |
---|---|
Author | Bill Gage |
Post date | 2005-02-22T23:18:13Z |
I will post what I found here.
There is an issue with getting a RecordCount when using DISTINCT in
the SQL statement of a TIB_Dataset.
Essentially if the user uses the following syntax for thier distinct
statement the RecordCount fails.
SELECT DISTINCT(MyField) FROM MyTable
You will get the error that there is a closed parens at the end of
the CountSQL statement. There is nothing wrong with the above
syntax when using DISTINCT.
Essentially if you put a space after the DISTINCT keyword the
problem goes away, but if there wasn't a space the error occurs.
Also you cannot strip off the Parens because it would kill the
following.
SELECT DISTINCT(Max(MyField)) FROM MyTable
I thought I fixed this by just stripping the close paren off the
end, but then it brings up another error of the user placed a space
after the DISTINCE.
Unfortunately I could not invest anymore time to correct the issue.
However I know the problem is in this location.
Unit - IB_Parse
procedure - MakeCountSQL
Bill
There is an issue with getting a RecordCount when using DISTINCT in
the SQL statement of a TIB_Dataset.
Essentially if the user uses the following syntax for thier distinct
statement the RecordCount fails.
SELECT DISTINCT(MyField) FROM MyTable
You will get the error that there is a closed parens at the end of
the CountSQL statement. There is nothing wrong with the above
syntax when using DISTINCT.
Essentially if you put a space after the DISTINCT keyword the
problem goes away, but if there wasn't a space the error occurs.
Also you cannot strip off the Parens because it would kill the
following.
SELECT DISTINCT(Max(MyField)) FROM MyTable
I thought I fixed this by just stripping the close paren off the
end, but then it brings up another error of the user placed a space
after the DISTINCE.
Unfortunately I could not invest anymore time to correct the issue.
However I know the problem is in this location.
Unit - IB_Parse
procedure - MakeCountSQL
Bill
--- In IBObjects@yahoogroups.com, "Bill Gage" <wcgage@y...> wrote:
>
> Where do I post fixes to the source code?
>
> Bill