Dynamic Table Name on Select Into

  • SQLGal

    Valued Member

    Points: 54

    Comments posted to this topic are about the item Dynamic Table Name on Select Into

  • akljfhnlaflkj

    SSC Guru

    Points: 76202

    Not sure if I have a place for this anywhere right now. But I do enjoy reading other people's code looking for ideas. Thanks.

  • Cuppadan

    SSC Enthusiast

    Points: 107

    Could this be adapted to copy data to a separate database in the same instance. We perform mostly database to database copying.


    SELECT my-column1, my-column2

    INTO [my-2nd-database].[schema].[mytable]

    FROM [my-1st-database].[schema].[mytable]

Viewing 3 posts - 1 through 3 (of 3 total)

You must be logged in to reply to this topic. Login to reply