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 |
|
densma
Starting Member
21 Posts |
Posted - 2004-05-27 : 12:30:39
|
| trying to create Delete stored procedure with where clause but when i pass parameter i get 0 row(s) affectedit's wont deletehere my codecreate PROCEDURE deldispute(@id char, @ticket char)AS DELETE FROM TBLES where theirid=@id and ticket=@ticketwht's wrong with that code and why it wont delete? |
|
|
Kristen
Test
22859 Posts |
Posted - 2004-05-27 : 14:26:46
|
| Do yuo need a SIZE after the char definition?Kristen |
 |
|
|
X002548
Not Just a Number
15586 Posts |
Posted - 2004-05-27 : 14:33:16
|
Unless it's 1 byte longDECLARE @x varcharSELECT @x = '123456789012345678901234567890123456789012345678901234567890'SELECT @x I thought it defaulted to 30 though....Brett8-) |
 |
|
|
LarsG
Constraint Violating Yak Guru
284 Posts |
Posted - 2004-05-27 : 14:55:21
|
quote: I thought it defaulted to 30 though...
cast(v as varchar) that defaults to 30 for some inconsistent reason. |
 |
|
|
tkizer
Almighty SQL Goddess
38200 Posts |
Posted - 2004-05-27 : 15:07:06
|
| I'm guessing that the parameters aren't being passed properly. What happens when you execute the stored procedure from Query Analyzer?Tara |
 |
|
|
|
|
|