Subject | Re: [Firebird-Java] fixed column names handling and server warnings |
---|---|
Author | Blas Rodriguez Somoza |
Post date | 2002-10-24T13:03:12Z |
Hello
Excuse me, but I don't pay attention to the thread and now I found that
there is a problem with the solution implemented.
In 14.3.2 of the JDBC 3.0 specification, states who the findColumn must
behave:
"Column names supplied to getter methods are case insensitive. If a select
list contains the same column more than once, the first instance of the
column will be returned"
So excluding the quoted identifiers case, which can be used to select a
column which is not the first one, when finding a column, the search must be
case-insensitive and the first column returned.
Related with the findColumn implementation there is a performance bug. I
test that and for a table with 18 numeric int and float fields the
findColumn method uses 40% of the total time.
I will correct that in the CVS if there is no opposition.
Regards.
Blas Rodriguez Somoza
Excuse me, but I don't pay attention to the thread and now I found that
there is a problem with the solution implemented.
In 14.3.2 of the JDBC 3.0 specification, states who the findColumn must
behave:
"Column names supplied to getter methods are case insensitive. If a select
list contains the same column more than once, the first instance of the
column will be returned"
So excluding the quoted identifiers case, which can be used to select a
column which is not the first one, when finding a column, the search must be
case-insensitive and the first column returned.
Related with the findColumn implementation there is a performance bug. I
test that and for a table with 18 numeric int and float fields the
findColumn method uses 40% of the total time.
I will correct that in the CVS if there is no opposition.
Regards.
Blas Rodriguez Somoza
----- Original Message -----
From: "Roman Rokytskyy" <rrokytskyy@...>
To: <Firebird-Java@yahoogroups.com>
Sent: Friday, October 18, 2002 4:33 PM
Subject: [Firebird-Java] fixed column names handling and server warnings
> Hi,
>
> I have fixed bug in column names handling as we agreed before:
>
> 1. strip double quotes from column name if present.
>
> 2. perform case-sensitive search in column names and aliases and
> return position if found.
>
> 3. if name contained double quotes, throw exception that no column
> was found. we assume that person passing column name in double quotes
> knows what he's doing.
>
> 4. perform case-insensitive search
>
> 5. throw an exception if previous step found nothing.
>
> Also I added support of server warnings. Now they are added as
> SQLWarning to a connection warnings.
>
> Please update your sources.
>
> Best regards,
> Roman Rokytskyy
>
>
>
> To unsubscribe from this group, send an email to:
> Firebird-Java-unsubscribe@yahoogroups.com
>
>
>
> Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/
>
>
>