Quantcast
Channel: Forum Getting started with SQL Server
Viewing all articles
Browse latest Browse all 7129

SQL Where clause add both conditions like

$
0
0

SQL Where clause add both conditions are in a single query  like 

declare @number = null
--if @number is null then
1)select * from table  where t.number is null

--if @number is not null then
2)select * from table where number  = @number  

= select * from table where?

all are in within the function 

and most important

declare @number = null,@age = 2

then

 

Viewing all articles
Browse latest Browse all 7129

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>