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 |
|
sql_mad
Starting Member
5 Posts |
Posted - 2007-07-26 : 04:47:15
|
| i came across the following syntax, can anyone explain what the purpose of the comments and the 'as' keyword are hereselect "*/ DECLARE @id int" as "/*" |
|
|
shallu1_gupta
Constraint Violating Yak Guru
394 Posts |
Posted - 2007-07-26 : 05:14:39
|
| for what it is being used??its just returning a column " /* " with value "*/ DECLARE @id int " |
 |
|
|
sql_mad
Starting Member
5 Posts |
Posted - 2007-07-26 : 05:33:42
|
| its part of a script which is used to dynmaically generate another script based on values in a table:select "*/ DECLARE @id int" as "/*"select "*/ DECLARE @c char(10)" as "/*"select "*/ Select @c = 'enroll'" as "/*"select "*/ Select @id = parm_id from info_table where parm_c = @c and coll_c = '' " as "/*"select distinct " exec parmu_row "+convert(varchar, ip.id)+", '"+ip.n+"', 'sominfo', 'someinfo', 'someinfo', 'someinfo', 'someinfo', @id, 'Y', '46544'" as '--' from t_info ipwhat is the purpose of the ' as ' and ' "/*" ' at the end of each line can you tell me? |
 |
|
|
X002548
Not Just a Number
15586 Posts |
|
|
|
|
|
|
|