| |

VerySource

 Forgot password?
 Register
Search
Author: ozms123

ACCESS time query ...

[Copy link]

0

Threads

1

Posts

2.00

Credits

Newbie

Rank: 1

Credits
2.00

 China

Post time: 2020-8-4 11:15:01
| Show all posts
CString strTime = "2002-2-1";
CString strSQL;
strSQL.Format("Select * From TableName where DateType = #%s#",strTime );
Reply

Use magic Report

2

Threads

17

Posts

13.00

Credits

Newbie

Rank: 1

Credits
13.00

 China

 Author| Post time: 2020-8-6 21:15:01
| Show all posts
Everyone upstairs meant to set the date field as text "????
But my ACCESS date field is set to "time/date" type! It is not a character type
Reply

Use magic Report

0

Threads

4

Posts

5.00

Credits

Newbie

Rank: 1

Credits
5.00

 China

Post time: 2020-8-6 22:15:01
| Show all posts
The above methods are all possible
You can build a query in Access, switch to SQL view and try it with SQL statement
Select * From TableName where DateType = #2017-1-11#
Reply

Use magic Report

0

Threads

1

Posts

2.00

Credits

Newbie

Rank: 1

Credits
2.00

 China

Post time: 2020-8-6 23:30:01
| Show all posts
The methods upstairs are all right. It may be that the date format you entered is different from the date format you access
Reply

Use magic Report

You have to log in before you can reply Login | Register

Points Rules

Contact us|Archive|Mobile|CopyRight © 2008-2023|verysource.com ( 京ICP备17048824号-1 )

Quick Reply To Top Return to the list