OracleDialectExt Fix

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

OracleDialectExt Fix

Aynor, Kailash
Developers,
    Can someone put in fix for obvious bug below that checks for TIMESTAMP (upper case) with lowercase nativeColumnTypeName.

In squirrel_sql/fw/dialects/OracleDialectExt.java


        @Override

+       public int getJavaTypeForNativeType(String nativeColumnTypeName)

+       {

+              if (nativeColumnTypeName.toLowerCase().equals("nvarchar2")) {

+                      return Types.NVARCHAR;

+              }

+              if (nativeColumnTypeName.toLowerCase().equals("nchar")) {

+                      return Types.NCHAR;

+              }

+              if (nativeColumnTypeName.toLowerCase().equals("nclob")) {

+                      return Types.NCLOB;

+              }

+              if (nativeColumnTypeName.toLowerCase().startsWith("TIMESTAMP")) {

+                      return Types.TIMESTAMP;

+              }

+              return super.getJavaTypeForNativeType(nativeColumnTypeName);

+       }

Thanks.
Kailash Aynor


This message contains confidential information and is intended only for the individual named. If you are not the named addressee, you should not disseminate, distribute, alter or copy this e-mail. Please notify the sender immediately by e-mail if you have received this e-mail by mistake and delete this e-mail from your system. E-mail transmissions cannot be guaranteed to be secure or without error as information could be intercepted, corrupted, lost, destroyed, arrive late or incomplete, or contain viruses. The sender, therefore, does not accept liability for any errors or omissions in the contents of this message which arise during or as a result of e-mail transmission. If verification is required, please request a hard-copy version. This message is provided for information purposes and should not be construed as a solicitation or offer to buy or sell any securities or related financial instruments in any jurisdiction.
------------------------------------------------------------------------------
This SF.net email is sponsored by Windows:

Build for Windows Store.

http://p.sf.net/sfu/windows-dev2dev
_______________________________________________
Squirrel-sql-develop mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/squirrel-sql-develop
Reply | Threaded
Open this post in threaded view
|

Re: OracleDialectExt Fix

Gerd Wagner-3
On 02.07.2013 21:45, Aynor, Kailash wrote:
> Developers,
>      Can someone put in fix for obvious bug below that checks for TIMESTAMP (upper case) with lowercase nativeColumnTypeName.
>
Is committed to our Git repo. Will be available in future snapshots and
versions.

Thanks

Gerd



> In squirrel_sql/fw/dialects/OracleDialectExt.java
>
>
>          @Override
>
> +       public int getJavaTypeForNativeType(String nativeColumnTypeName)
>
> +       {
>
> +              if (nativeColumnTypeName.toLowerCase().equals("nvarchar2")) {
>
> +                      return Types.NVARCHAR;
>
> +              }
>
> +              if (nativeColumnTypeName.toLowerCase().equals("nchar")) {
>
> +                      return Types.NCHAR;
>
> +              }
>
> +              if (nativeColumnTypeName.toLowerCase().equals("nclob")) {
>
> +                      return Types.NCLOB;
>
> +              }
>
> +              if (nativeColumnTypeName.toLowerCase().startsWith("TIMESTAMP")) {
>
> +                      return Types.TIMESTAMP;
>
> +              }
>
> +              return super.getJavaTypeForNativeType(nativeColumnTypeName);
>
> +       }
>
> Thanks.
> Kailash Aynor
>


------------------------------------------------------------------------------
This SF.net email is sponsored by Windows:

Build for Windows Store.

http://p.sf.net/sfu/windows-dev2dev
_______________________________________________
Squirrel-sql-develop mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/squirrel-sql-develop