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 |
|
joerage
Starting Member
4 Posts |
Posted - 2007-09-07 : 16:57:55
|
| If I run the following statement select 1 & 0 | 1I get the result expected.My problem is I have a string representation of the logic. I tried to evaluate it using dynamic sql, and it would not work. Here is the code I used:declare @d nvarchar(10)set @d = 'select 1 & 0 | 1'EXEC sp_executesql @dAny idea how to make this work?Thanks,Jonathan |
|
|
harsh_athalye
Master Smack Fu Yak Hacker
5581 Posts |
Posted - 2007-09-07 : 17:11:24
|
Just changedeclare @d nvarchar(10) todeclare @d nvarchar(50) Harsh AthalyeIndia."The IMPOSSIBLE is often UNTRIED" |
 |
|
|
Lamprey
Master Smack Fu Yak Hacker
4614 Posts |
Posted - 2007-09-07 : 17:11:59
|
Try this: declare @d nvarchar(16)set @d = 'select 1 & 0 | 1'EXEC sp_executesql @d |
 |
|
|
|
|
|