File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes JDBC and the fly likes Identify not null columns Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login
JavaRanch » Java Forums » Databases » JDBC
Reply Bookmark "Identify not null columns" Watch "Identify not null columns" New topic
Author

Identify not null columns

Kishan Kumar
Ranch Hand

Joined: Sep 26, 2000
Posts: 130
Hi,
Is there is anyway we can identify columns with "not null" constraint in a given table.
Thanks for your time.


Regards,<BR>V. Kishan Kumar
Jamie Robertson
Ranch Hand

Joined: Jul 09, 2001
Posts: 1879

ResultSetMetaData.isNullable:
public int isNullable(int column) throws SQLException
Indicates the nullability of values in the designated column.
Parameters:
column - the first column is 1, the second is 2, ...
Returns:
the nullability status of the given column; one of columnNoNulls, columnNullable or columnNullableUnknown
Throws:
SQLException - if a database access error occurs
[ July 30, 2002: Message edited by: Jamie Robertson ]
 
I agree. Here's the link: http://ej-technologies/jprofiler - if it wasn't for jprofiler, we would need to run our stuff on 16 servers instead of 3.
 
subject: Identify not null columns
 
Similar Threads
pls answer this??
Developing website in English and Arabic
Getting 0 rows returned when selecting with null values
Speak(read) a text when app is launched
How to implement equals for DB model?