View previous topic :: View next topic
|
Author |
Message |
vasa Warnings : 1 New User
Joined: 10 Jan 2006 Posts: 9
|
|
|
|
How to access null values from the table by a query?
please send me the query. |
|
Back to top |
|
|
ragshere
New User
Joined: 20 Dec 2004 Posts: 70
|
|
|
|
vasa,
use this below query as a sample
select * from tablename
where col1 is null
Thanks
Rags |
|
Back to top |
|
|
KS
New User
Joined: 28 Feb 2006 Posts: 91 Location: Chennai
|
|
|
|
Hi,
Consider the employee table with column PROJECT nullable. How can you get a list of employees who are not assigned to any project or rows that have null values in PROJECT
SELECT EMPNO
FROM EMP
WHERE PROJECT IS NULL;
The standard to be followed for writing a select st is to give the name of the column to be selected than a '*'.
Thanks,
KS |
|
Back to top |
|
|
KS
New User
Joined: 28 Feb 2006 Posts: 91 Location: Chennai
|
|
|
|
Hi,
Hope am correct abt the standard.If not , kindly correct .
Thanks,
KS |
|
Back to top |
|
|
martin9
Active User
Joined: 01 Mar 2006 Posts: 290 Location: Basel, Switzerland
|
|
|
|
hy,
just note:
if you use the INTO variables clause,
you should never forget to give with
the variable also an indicator variable.
because if the value is null and you give no
indicator, your sql statement will abend.
martin9 |
|
Back to top |
|
|
|