比较日期不会在水晶报告中给出记录 [英] Comparing Date does not give records in crystal report

查看:65
本文介绍了比较日期不会在水晶报告中给出记录的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在ms访问中查询我需要比较日期...我需要比较的数据库字段是TRDATE(数据类型是datetime,格式是SHort Date)..当我在开发PC中运行以下查询时32位,它给了我记录..



从NTRANS1213中选择*(NTRANS1213.TRDATE BETWEEN#3/26/2013#AND#3/26 / 2013#)



这两个日期都来自软件中的datetimepicker。







当我从Office 2007的查询分析器运行64位PC时,同样的查询,我得到记录..



但是如果我运行应用程序,即使这些日期之间有2条记录,也不会恢复任何记录。

我无法弄清楚问题。请帮助我......

I have query in ms access where I need to compare date...My database field I need to compare is TRDATE(datatype is datetime and format is SHort Date)..When I run the below query in development PC which is 32-bit,it gives me records..

"Select * from NTRANS1213 where(NTRANS1213.TRDATE BETWEEN #3/26/2013# AND #3/26/2013#)"

Both dates are taken from datetimepicker in software.



The same query when I run in 64-bit PC from query analyser of Office 2007,I get records..

But If I run application,no records are retrived even though there are 2 records between these dates.
I am not able to figure out the problem.Please help me...

推荐答案

检查数据库中是否有包含日期​​的列。通过否定过滤条件,可能日期也可能包含时间部分。一直发生。 :-)



如果有时间部分,请使用date1.Date仅输入日期部分。
Check you database for the columns containing the dates. Probably date may contain time part also there by negating the filter condition. Happens all the time. :-)

If there is time part, use date1.Date to enter date part only.


这篇关于比较日期不会在水晶报告中给出记录的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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