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 |
|
Soultech
Starting Member
1 Post |
Posted - 2007-01-05 : 06:27:03
|
| Hi every one,Iam new to SQL, I have to write a stored procedure to validate registration number so that if the given registration nuber is in the tabel then stored procedure should return true otherwise fals.can any one please guide me to write this stored procedure.thanks |
|
|
harsh_athalye
Master Smack Fu Yak Hacker
5581 Posts |
Posted - 2007-01-05 : 06:47:09
|
Something like this:Create Proc p1( @regno int)asbeginIf Exists (Select * from tbl where registrationno = @regno) Return 1Else Return 0end Harsh AthalyeIndia."The IMPOSSIBLE is often UNTRIED" |
 |
|
|
|
|
|