|
Posted by BJMurphy on 02/13/07 21:01
Hi All,
I am used to other SQL engines, and have a few basic questions--
1)If I wanted to conditionally drop a table, does SQL Server have a
way to natively do this? Many SQL implementations will allow
something like:
CREATE OR REPLACE tablename AS
SELECT
x,y,z
FROM sourcetable
;
Does SQL Server have something like this? This syntax, both the
"create table as select" syntax and the "create or replace" syntax
seem to cause problems.
2) Some of our existing queries have a keyword, "GO" where I would
otherwise expect a semi-colon. Is there a functional difference
between the two? I seem to be able to replace the "GO" keywords with
semi-colons without any changes in how the script behaves, but I
thought I would check and see if anyone has advice about the
differences here.
Thanks in advance,
Ben
Navigation:
[Reply to this message]
|