将数值类型的数据库值插入Excel时出现问题 [英] Problem inserting database value of numeric type into Excel

查看:77
本文介绍了将数值类型的数据库值插入Excel时出现问题的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

您好专家。

我制作了一个程序,其中SQL表中的数据被传输到Excel工作表。

当字段的数据类型为Integer时,它可以正常工作,但是当字段的数据类型是数字时,它可以正常工作。它产生错误应用程序错误或对象定义的错误但是我不能将表的数据类型从Numeric更改为Integer。

请提供一些想法。


提前谢谢。

Hello expert.
I made a program in which the data from an SQL table is transferred to an Excel sheet.
When the data type of a field is Integer it works fine, but when the data type of a field is "numeric" it produces the error "APPLICATION ERROR OR OBJECT DEFINED ERROR" but I can''t change the data type of the table from Numeric to Integer.
Please provide some idea.

Thanks in advance.

推荐答案

嗨。


我不确定错误是否必须对字段的数据类型执行任何操作。

您是否检查字段是否为空?

在填充Excel单元格之前检查是否为空。


问候,

Veena。
Hi.

I''m not sure if the error has got to do anything with the data type of the Field.
Did you check if the field is Null?
Before populating an Excel cell check for Not Null.

Regards,
Veena.


你好专家。

我没有正确理解如何检查Excel单元格是否为空。

请提供一些方法。

谢谢。


Hello expert.
I am not properly understanding how I can check the Excel cell for not null.
Please provide some method.
Thanks.



我不确定如果错误必须对字段的数据类型执行任何操作。

您是否检查字段是否为空?

在填充Excel单元格之前检查是否为空。
I''m not sure if the error has got to do anything with the data type of the Field.
Did you check if the Field is Null?
Before populating the Excel cell check for Not Null.



我无法正确理解如何检查Excel单元格是否为空。
I am not properly understanding how I can check the Excel cell for not null.



Veena意味着检查该值是否为空,之前将其复制到Excel中的单元格。


您能否告诉我们您在尝试复制到Excel的字段中有什么价值?如果您向我们展示了执行复制的代码,也可能会有所帮助。

Veena meant to check that the value is not null, before you copy it to the cell in Excel.

Can you tell us what value is in the field, that you are trying to copy to Excel? It might help if you showed us the code that does the copy, too.


这篇关于将数值类型的数据库值插入Excel时出现问题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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