Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
| Author |
Topic |
|
soorajtnpki
Posting Yak Master
231 Posts |
Posted - 2008-11-11 : 04:30:38
|
| HI, suppose i have column called name and this column can be null. so if i do the the checking in the query select * from table where name <> ''. will this query consider nullspls replyok tanx.. |
|
|
visakh16
Very Important crosS Applying yaK Herder
52326 Posts |
Posted - 2008-11-11 : 04:32:51
|
| nope. under default settings NULL is not considered as a value so <> ignores NULL |
 |
|
|
soorajtnpki
Posting Yak Master
231 Posts |
Posted - 2008-11-11 : 04:42:08
|
| ok tanx, the only checking we can made directly with null is -- column is null in where condition of query right..and besides we can use isnull and coaelesce functionsam i right?ok tanx.... |
 |
|
|
visakh16
Very Important crosS Applying yaK Herder
52326 Posts |
Posted - 2008-11-11 : 04:45:29
|
| yup. Unless you've changed default ANSI NULLS setting |
 |
|
|
madhivanan
Premature Yak Congratulator
22864 Posts |
Posted - 2008-11-11 : 05:17:45
|
| If you want to have null values too,select * from table where name <> '' or name is nullMadhivananFailing to plan is Planning to fail |
 |
|
|
AShehzad
Starting Member
8 Posts |
|
|
|
|
|