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.

 All Forums
 SQL Server 2000 Forums
 SQL Server Development (2000)
 copying table with a dynamic name

Author  Topic 

Kode
Starting Member

23 Posts

Posted - 2000-12-10 : 15:43:05
I am doing this real simple insert into statement

SELECT *
INTO table1_bak
FROM table1

And I can't figure out how to add a dynamic name to the copied table. Like adding a date to the name being inserted. This obviously doesn't work but you can see what I am trying

SELECT *
INTO table1_bak + getdate()
FROM table1

I am using mssql, do I need to learn how to do the same thing but with the create table function? I am trying to keep it simple since I am a newbie.

   

- Advertisement -