logo
Welcome Guest! To enable all features please Login or Register.

Notification

Icon
Error

Options
Go to last post Go to first unread
jbiza  
#1 Posted : Monday, March 19, 2018 9:49:28 AM(UTC)
jbiza

Rank: Newbie

Groups: Registered
Joined: 3/19/2018(UTC)
Posts: 2
Czech Republic
Location: Havlickuv Brod

I am reading data from CSV file (Timestamp(date), Value (float)). Connection is fine. I can see corect data in table and also chart is fine.
I have problem when I try create restriction on date (date between 'somedate1' and 'somedate2'). I receive error message "ERROR [22018] [Microsoft][ODBC text Driver] Data type mismatch in criteria expression".
Column Timestamp is set to date format in ODBC.

Knows anybody solution please. Thanks
epf  
#2 Posted : Tuesday, March 20, 2018 11:44:25 AM(UTC)
epf

Rank: Administration

Groups: Administrators
Joined: 12/20/2013(UTC)
Posts: 542
Switzerland

Thanks: 7 times
Was thanked: 76 time(s) in 74 post(s)
this is related to the ODBC Text driver, I do not know if it supports the date time restrictions.
Perhaps the SQL generated must have a special format for datetime.
jbiza  
#3 Posted : Sunday, March 25, 2018 1:23:02 PM(UTC)
jbiza

Rank: Newbie

Groups: Registered
Joined: 3/19/2018(UTC)
Posts: 2
Czech Republic
Location: Havlickuv Brod

Thank you for ansver.
I used construction "where (day(F2) between day('@Date1') and day('@Date2')) and (month(F2) between month('@Date1') and month('@Date2')) and (year(F2) between year('@Date1') and year('@Date2'))". I dont know if it is the best solution but works.
Users browsing this topic
Forum Jump  
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.