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 |
|
odeborne
Starting Member
1 Post |
Posted - 2001-05-25 : 05:45:21
|
| Dear All,I'm stuck with this problem:First, I would like to change dynamically the alias for each column returns by my stored proc.I've tried this but it didn't work:DECLARE @ColAlias sysnameSET @ColAlias = 'test'SELECT field1 AS @ColAlias FROM tableSecond, I've written a user defined function which returns a string (column alias) according to the input value (field name), so I can centralize all the alias. So, I would like to do:SELECT field1 AS MyFunction('field1') FROM tableIs it possible, please help!!!Thanks, Olivier. |
|
|
|
|
|