I am trying to create a new table using SELECT INTO but it fails because the column names from the two source tables are identical.
select sysobjects.name, syscolumns.name into DP_AUDIT
from sysobjects, syscolumns
where sysobjects.id = syscolumns.id
and sysobjects.xtype='U'
Is there a way to rename the columns to prevent the conflict? Any help would be appreciated.