gpt4 book ai didi

SQL Server 2008 : BULK INSERT csv - is it possible to choose fields?

转载 作者:行者123 更新时间:2023-12-03 02:14:00 24 4
gpt4 key购买 nike

我正在做:

BULK INSERT CSVTest FROM 'c:\csvtest.txt'
WITH
(FIELDTERMINATOR = ',',
ROWTERMINATOR = '\n')
GO

--Check the content of the table.
SELECT *
FROM CSVTest
GO

--Drop the table to clean up database.
SELECT *
FROM CSVTest
GO

是否可以仅插入 csv 中的特定字段?

最佳答案

或者,您可以bulk insert into a view .

另请参阅this question .

关于SQL Server 2008 : BULK INSERT csv - is it possible to choose fields?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/3893619/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com