i want to create procedure for create table in sql server
2005
for example
create procedure create_table
@table varchar(20)
as
create @table(
id int,
name char(20)
)
but it will get error
what is solution?
Answer Posted / pradip jain
create procedure create_table
@table1 varchar(20)
as
Begin
Declare @table table
(
id int,
name char(20)
)
end
If you refer question only syntax error is there!!! as table
variable can not use using create command.
Is This Answer Correct ? | 2 Yes | 0 No |
Post New Answer View All Answers
Tell me what is the difference between locking and multi-versioning?
What is scrollable cursor?
What is a mixed extent?
What is the ‘fillfactor’?
Explain the different types of joins?
What are temporal tables in sql server 2016?
What are the 2 types of classifications of constraints in the sql server?
Explain the difference between HTTP and HTTPS in database?
What is the difference between composite index and covering index?
Mention what are the different types of ssrs reports?
What is the difference between update lock and exclusive lock?
is there a column to which a default can't be bound? : Sql server database administration
What is database mirroring?
What is the partitioning method?
Explain what are the authentication modes in sql server?