Copying data from secondary data file

  • Dear Guys,

    I have table that is stored in the secondary data file.

    If I use select * into TableName statement to copy the data, by default it is stored in the primary data file. How to copy the data from secondary to secondary data file using the above select statment. Pl. help me out?

    regards

    nazeer

  • I guess you have a typo in here and you're asking how to move the data from secondary to primary, right?

    Probably the best solution here is

    CREATE CLUSTERED INDEX....WITH DROP EXISTING ON primary

    --
    Frank Kalis
    Microsoft SQL Server MVP
    Webmaster: http://www.insidesql.org/blogs
    My blog: http://www.insidesql.org/blogs/frankkalis/[/url]

  • Only other way I can think of is to

    Create table...on [secondary]

    and then insert the recs. Select into doesn't allow the 'on filegroup' option.



    Michelle

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

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