查询以选择特定日期和时间之间的记录 [英] Query to select records between particular Date and Time
本文介绍了查询以选择特定日期和时间之间的记录的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
Hai All,
i希望在特定日期时间范围内从表中检索记录。
查询是
Hai All,
i want to retrive records from a table between perticular datetime range.
the query is
展开 | 选择 | < span class =codeLinkonclick =WordWrap(this);> Wrap | 行号
推荐答案
Hai All,
i希望从特定日期时间范围之间的表中检索记录。
查询是
select * from geo_trip_history
t '2008-02-02''和''2008-02-29''之间的.tr_start_date和
t.tr_end_date be补间''2008-02-02''和''2008-02-29''和
t.tr_start_time> ='''010000''和t.tr_end_time< =''230000 '';
触发此查询会产生5条记录..
但是当我改变t.tr_end_time< ='''010000''时/>
这给了我0条记录。
但这不是理想的结果。它也应该给出5条记录。
请回复..
我该怎样做才能在''2008-02-02 010000''''2008-02-29 010000''之间回复记录。
Hai All,
i want to retrive records from a table between perticular datetime range.
the query is
select * from geo_trip_history where
t.tr_start_date between ''2008-02-02'' and ''2008-02-29'' and
t.tr_end_date between ''2008-02-02'' and ''2008-02-29'' and
t.tr_start_time >=''010000'' and t.tr_end_time <=''230000'';
firing this query results in 5 records..
but when i change the t.tr_end_time <=''010000''
this is giving me 0 records.
but this is not the desired result.It should give 5 records for this too.
kindly reply ..
wht should i do to retrive records between ''2008-02-02 010000'' to ''2008-02-29 010000'' .
ttr.start_date是否只保留日期值或时间?
Does ttr.start_date hold only date value or time as well?
ttr.start_date是否仅保留日期值或时间?
Does ttr.start_date hold only date value or time as well?
t.tr_start_date和t.tr_end_date是日期并且
t.tr_start_time和t.tr_end_time是Time feilds。
t.tr_start_date and t.tr_end_date are date feilds and
t.tr_start_time and t.tr_end_time are Time feilds.
t.tr_start_date和t.tr_end_date是日期和
t.tr_start_time和t.tr_end_time是Time feilds。
t.tr_start_date and t.tr_end_date are date feilds and
t.tr_start_time and t.tr_end_time are Time feilds.
试试这个:
Try this:
展开 | 选择 | Wrap | 行号
这篇关于查询以选择特定日期和时间之间的记录的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文