Microsoft Excel 8.0读取:只需要将具有数据的行插入到数据表而不是所有行中 [英] Microsoft Excel 8.0 reading : Needs to insert only rows which have data into datatable not all rows

查看:95
本文介绍了Microsoft Excel 8.0读取:只需要将具有数据的行插入到数据表而不是所有行中的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

大家好,



我使用的是使用Oledb连接的Micrsoft excel 8.0版本。



我有一个Excel模板,它有几乎所有10000行,因为它只有前3行数据。



使用OledDb填充数据表时,它插入10000条记录进入数据表。但我想要的是,只有数据的行。意味着它应该只在数据表中插入3条记录。



如何才有可能。任何人都可以帮忙吗?

Hi all,

I am using Micrsoft excel 8.0 version using Oledb connection.

I have one Excel template it has alomst all 10000 rows , in that it has only first 3 rows data.

While filling into data table using OledDb, it is inserting 10000 records into data table. but I want like, rows which have data only. means it should insert only 3 records into data table.

How it can be possible. Can any one help on this?

推荐答案

你的插入查询是什么样的?将null检查添加到where语句(或select语句)中应该这样做。
What does your insert query look like? Adding a null check into your where statement (or select statement for that matter) should do it.


这篇关于Microsoft Excel 8.0读取:只需要将具有数据的行插入到数据表而不是所有行中的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆