Forum Moderators: open

Message Too Old, No Replies

SQL String

         

stevelibby

3:48 pm on Feb 23, 2007 (gmt 0)

10+ Year Member



Is it possible to split a sql query string and include if then else and depending on the answer add to the string?

TheNige

8:20 pm on Feb 23, 2007 (gmt 0)

10+ Year Member



Are you creating dymanic SQL or using stored procedures. You can create any kind of SQL string that you want. Can you give an example of the type of query you want to write?

sgietz

6:43 pm on Mar 1, 2007 (gmt 0)

10+ Year Member



Sure you can. A SQL query is treated like any other string. That gives you enormous flexibility.

Please post example of what you want to do.

Ossifer

12:39 am on Mar 12, 2007 (gmt 0)

10+ Year Member



Another option would be to have multiple connection strings in the web.config and use the if then else logic to select the one you want.