Import fixed width text to SQL

前端 未结 5 1202
梦谈多话
梦谈多话 2020-12-15 14:50

We have records in this format:

99 0882300 25 YATES ANTHONY V MAY 01 12 04 123456 12345678

The width is fixed and we need to import it int

5条回答
  •  我在风中等你
    2020-12-15 15:23

    To import from TXT to SQL:

    CREATE TABLE #DaTable (MyString VARCHAR(MAX));

    BULK INSERT #DaTable FROM'C:\Users\usu...IDA_S.txt' WHITH ( CODEPAGE = 'RAW' )

提交回复
热议问题