While using a CREATE TABLE command I would like to use column names which have been determined within the same stored procedure (I want to set column names which represent a w/c date for display in a VB datagrid)
This is the kind of thing I mean...
-- I can determine date values from a calendar table
DECLARE @ColName char(8)
SELECT @ColName = '10/11/03'
DROP TABLE SkuPlan
CREATE TABLE SkuPlan
(
ItemCode char(15),
RecType char(1),
Description varchar(50),
@ColName int
)
This syntax isn't permitted, but any ideas how I could achieve the same effect?
Thanks
This is the kind of thing I mean...
-- I can determine date values from a calendar table
DECLARE @ColName char(8)
SELECT @ColName = '10/11/03'
DROP TABLE SkuPlan
CREATE TABLE SkuPlan
(
ItemCode char(15),
RecType char(1),
Description varchar(50),
@ColName int
)
This syntax isn't permitted, but any ideas how I could achieve the same effect?
Thanks