The Artima Developer Community
Sponsored Link

Java Answers Forum
java.sql.Types.NUL - DON'T USE IT!!

0 replies on 1 page.

Welcome Guest
  Sign In

Go back to the topic listing  Back to Topic List Click to reply to this topic  Reply to this Topic Click to search messages in this forum  Search Forum Click for a threaded view of the topic  Threaded View   
Previous Topic   Next Topic
Flat View: This topic has 0 replies on 1 page
Kondwani Mkandawire

Posts: 530
Nickname: spike
Registered: Aug, 2004

java.sql.Types.NUL - DON'T USE IT!! Posted: Feb 23, 2006 12:53 AM
Reply to this message Reply
Advertisement
java.sql.Types.NULL

Quote from java5 API:
"The constant in the Java programming language, sometimes referred to as
a type code, that identifies the generic SQL type NULL."

This actually returns 0. This has been extremely misleading and has caused
endless headaches.

I have no clue why in the hell they made it return an int when even
SQL itself accepts INTS and does not view them as NULL.

Which ever goofball wrote that probably din't have much understanding
of SQL, or if he/she did could have done a much better job at phrasing it.

In other databases, this will fly but run it against a large scale app.
with Postgres as the backend, because postgres handles foreign-key constraints
(which is obviously a good thing to make up for goof ball documentation such
as the above), I garrauntee you it will be a night-mare to work with or use.

My advice, just don't use it (to Sun, please eliminate it all together coz
its very misleading)...

Topic: Show c commnads in java Previous Topic   Next Topic Topic: General Question - User Notification

Sponsored Links



Google
  Web Artima.com   

Copyright © 1996-2019 Artima, Inc. All Rights Reserved. - Privacy Policy - Terms of Use