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


Please Help Members By Posting Answers For Below Questions

Tell me what is the difference between locking and multi-versioning?

573


What is scrollable cursor?

534


What is a mixed extent?

583


What is the ‘fillfactor’?

559


Explain the different types of joins?

558






What are temporal tables in sql server 2016?

471


What are the 2 types of classifications of constraints in the sql server?

576


Explain the difference between HTTP and HTTPS in database?

555


What is the difference between composite index and covering index?

501


Mention what are the different types of ssrs reports?

98


What is the difference between update lock and exclusive lock?

490


is there a column to which a default can't be bound? : Sql server database administration

529


What is database mirroring?

556


What is the partitioning method?

524


Explain what are the authentication modes in sql server?

494