Home Forums SQL Server 7,2000 T-SQL create a table on a 2nd SQL server via linked server RE: create a table on a 2nd SQL server via linked server

  • ok how about this: can you do this to the linked server? using the SELECT ...INTO feature, but make sure the where statement returns no rows, so it creates the table but does not populate it?:

     

    select actnbr,actname

    into newtable

    from gmact

    where 1=2

    select * from newtable

    actnbr             actname                                 

    ------------------ ----------------------------------------

    (0 row(s) affected)

    Lowell


    --help us help you! If you post a question, make sure you include a CREATE TABLE... statement and INSERT INTO... statement into that table to give the volunteers here representative data. with your description of the problem, we can provide a tested, verifiable solution to your question! asking the question the right way gets you a tested answer the fastest way possible!