Forum Replies Created

Viewing 15 posts - 76 through 90 (of 104 total)

  • RE: Recursive help needed

    Thanks. It was backwards. I get all the records now.

    However they are not sorted in a recursive manner. The data I posted yields misleading results as it was all...

  • RE: Help with replacing Superscript 2

    Thank you. I thought it would be something along those lines. I am using the NChar for the replace because once I tried Replace(Teststring,Char(8218),',') and that set all the field...

  • RE: Script to Backup A and Restore as B

    One thing leads to another. Your code worked. Now I have additional questions. When I restore GMF to A as I did origianlly using SSMS, shouldn't I be changing the...

  • RE: Script to Backup A and Restore as B

    The Results are in the attached jpg.

    What I find interesting is that the FileListOnly has a Logical name for the A log file as GMF_Log but the Physical name...

  • RE: Script to Backup A and Restore as B

    mathusa,

    Ok. I added that.

    restore filelistonly from disk='D:\SQLData\A.bak'

    RESTORE DATABASE B

    FROM DISK = 'D:\SQLData\A.bak'

    WITH REPLACE, MOVE 'A' TO 'D:\SQLData\B.mdf', MOVE 'A_Log' TO 'D:\SQLData\B_Log.ldf'

    ALTER DATABASE B

    MODIFY FILE (NAME = 'A', NEWNAME...

  • RE: Script to Backup A and Restore as B

    Martusha and Muthukkumaran Kaliyamoorthy,

    Thank you both. I am still doing something wrong.

    The table names are:

    A.bak

    A.mdf

    A_Log.ldf

    B.Mdf

    B_Log.ldf

    These 5 files are located in the D:\SQLData\ folder.

    Here is my current script:

    RESTORE DATABASE B

    FROM DISK...

  • RE: Script to Backup A and Restore as B

    Grasshopper,

    I hit a snag. When executing your code, I receive:

    The backup set holds a backup of a database other than the existing 'B' database.

    I think this will be cured if...

  • RE: Full Text Search "Contains" question

    Guys,

    Thanks for the info. I do appreciate the help since I know so little.

    pat

  • RE: Why SHRINKFILE is a very bad thing, and what to do about it.

    Thanks guys. I appreciate the explanation.

    pat

  • RE: Why SHRINKFILE is a very bad thing, and what to do about it.

    After reading the article I tried running the recommended resource at the bottom of the page, pr_rebuildindexes.sql. After cutting and pasting this into SQL Query Analyzer, I receive numerous errors...

  • RE: Best way to insert records from a CSV file

    Gatekeeper,

    Thanks. I did not see your post while I continued to work on this issue. You were 100% correct. When i used the full FormatFile the import was successful.

    This contradicts...

  • RE: Best way to insert records from a CSV file

    Steve,

    I have stumbled upon a half a##ed solution. If I first import the whole csv file into a SQL table that has all the rows. Then I do an Insert...

  • RE: Best way to insert records from a CSV file

    It seems to me that the formatfile should look more like

    9.0

    10

    1SQLCHAR00","0""

    2SQLCHAR00","2TimePoint""

    3SQLCHAR00","3rtPrice""

    4SQLCHAR00","0""

    5SQLCHAR00","0""

    6SQLCHAR00","6daPrice""

    7SQLCHAR00","0""

    8SQLCHAR00","0""

    9SQLCHAR00","9versifyId""

    10SQLCHAR00"\r"10extermalNodeID""

    If I do not include all the columns from the csv file in this definition, SQL server will not know...

  • RE: Best way to insert records from a CSV file

    Steve,

    Thank you for adding the Openrowset code. I tried it and it did not work. I received the message, "Invalid column number in the Format File c:\Formatfile.txt". I googled Openrowset...

  • RE: Best way to insert records from a CSV file

    Changebluesky,

    Thanks for the idea. I will be using VB to download them from the FTP site, to loop through the files and to do the Bulk Insert. The only thing...

Viewing 15 posts - 76 through 90 (of 104 total)