Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

MS Query

Status
Not open for further replies.

kiperez

Programmer
Feb 9, 2005
11
US
I'm having difficulty filtering on the current date in my MS Query from Excel.
The ODBC driver for Remedy has a $TIMESTAMP$ feature but I keep getting errors.
I've tried Now(), Currdate(), Current_Date, Today
everything I can think of even sysdate (like in Oracle) but nothing seems to please the MS Query tool. One would think Microsoft would allow you to use VBA commands but that type of sense obviously isn't in their vernacular.
Please help me if you can.
 
Hi,

Try Date()

Skip,

[glasses] [red]Be advised:[/red] The dyslexic, agnostic, insomniac, lays awake all night wondering...
"Is there really a DOG?" [tongue]
 
oh yeah... I tried that too... still no luck.
thanks for the suggestion though.
 
I found some article saying to use whatever the DBMS says to use... in this case it's $TIMESTAMP$... that doesn't work and I get an error saying "Driver]Data types are not appropriate for relatinoal operation"

ugh! I get that error for pretty much everything I try.
 

Here's a query that I am currently using...
Code:
SELECT H.F1, H.F2, H.`Workable WS`, H.`Workable NS`, H.`Short Buy Part`, H.`Short Make part`, H.`Short Make A & R`, H.`Short Make CCOE`, H.`Short Make MCOE`, H.`In File`, H.MDCN, H.`Buy WS`, H.`Buy NS`, H.`A&R WS`, H.`A&R NS`, H.`CCOE WS`, H.`CCOE NS`, H.`MCOE WS`, H.`MCOE NS`, H.`Workable WS1`

FROM `D:\temp\30-60-90_mach_CANADA_2005-03-10`.`History$` H

WHERE (Int(H.F1)=int(Date())) OR (H.F1={ts '2005-02-09 00:00:00'})


Skip,

[glasses] [red]Be advised:[/red] The dyslexic, agnostic, insomniac, lays awake all night wondering...
"Is there really a DOG?" [tongue]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top