linux下db2导入csv文件脚本,从文件csv导入db2(db2 import from file csv)

在尝试从CSV文件导入数据到DB2时,遇到导入成功但数据未显示的问题。通过检查发现,需要确保数据文件使用逗号作为分隔符或使用`COLDEL`参数指定分隔符。正确命令示例:`db2 import from "ABC.csv" OF DEL MODIFIED BY COLDEL; insert into abc(id,id2)`。" 110059166,7504529,Typore图床:服务器与客户端实现,"['Java', 'Spring Boot']
摘要由CSDN通过智能技术生成

从文件csv导入db2(db2 import from file csv)

我做了一个简单的例子,但它不起作用。 我连接到示例数据库

我的文件是ABC.csv

1; 2

2; 3

db2 import from "ABC.csv" OF DEL insert into abc(id,id2)

导入找到行,它说插入。

但是如果db2 select * from abc没有数字出现但是' - '

id id2

_ _

_ _

为什么?

表abc创建为(id int,id2 int)

I made a simple example, but it does not work. I connect to sample database

my file is ABC.csv

1;2

2;3

db2 import from "ABC.csv" OF DEL insert into abc(id,id2)

the import found the rows and it says that inserted.

but if db2 select * from abc no numbers appear but '-'

example

id id2

_ _

_ _

why?

the table abc is create as (id int, id2 int)

原文:https://stackoverflow.com/questions/35553959

更新时间:2

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值