tsql - "create if not exist" and "create table like" sql server query -


how can create table if table not exist. in case, want create table query :

select *  b 

that table in db , table b in db b. help?

if not exists (select [name] sys.tables [name] = 'a') select *  a.dbo.a b.dbo.b 

you can try .. simple one.


Comments

Popular posts from this blog

html5 - What is breaking my page when printing? -

html - Unable to style the color of bullets in a list -

c# - must be a non-abstract type with a public parameterless constructor in redis -