File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
A friendly place for programming greenhorns!
Big Moose Saloon
Register / Login
JDBC and Relational Databases
What's the significance of having null as a column ouput all nulls in SQL?
Joined: Apr 01, 2011
Sep 07, 2012 04:22:32
select column_name, null from table_name;
what is the use of null here ?
Joined: Apr 06, 2010
Sep 07, 2012 04:25:54
It's going to put a column in the output containing all nulls.
Pretty pointless by itself, but there may be cases where it's useful in conjunction with some other constructions. For example:
INSERT INTO ....
SELECT column_name, null
I agree. Here's the link:
subject: What's the significance of having null as a column ouput all nulls in SQL?
Complicated SQL query help
Error java.sql.SQLException: ORA-00923
get column value from column name
how to execute sqlplus and sql commands using java
MS SQL JOIN query not returning all results
All times are in JavaRanch time: GMT-6 in summer, GMT-7 in winter
| Powered by
Copyright © 1998-2015