|
|
|||||||||
|
|||||||||
| |||||||||
|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
|
|
Get inside! Sample the range of functionality easily built with JMSL Library for Time Series Data Analysis, Heat Maps, Portfolio Optimization, Monte Carlo Simulation, Stock Price Charting and more. Download Now! |
|
#1
|
|||
|
|||
|
I am trying to run a query that uses dates..
i want to find all records between 2 dates the date in access is of data type "date/time" this is what im trying but doesnt work ![]() SQLQuery = "SELECT *" SQLQuery = SQLQuery & "FROM Courses" SQLQuery = SQLQuery & " WHERE Start_Date BETWEEN " SQLQuery = SQLQuery & "'#" SQLQuery = SQLQuery & startDate SQLQuery = SQLQuery & "'#'" SQLQuery = SQLQuery & " AND" SQLQuery = SQLQuery & "'#" SQLQuery = SQLQuery & endDate SQLQuery = SQLQuery & "#'" any help???? thanks in advance R |
|
#2
|
|||
|
|||
|
|
|
#3
|
||||
|
||||
|
This is the proper t-sql syntax:
Code:
SELECT * FROM dbo.Orders WHERE OrderDate BETWEEN '7/4/1996' AND '7/9/1996'
__________________
mr... mike.rusaw@realpage.com RalPage, Inc. "I have made this letter longer than usual, only because I have not had the time to make it shorter." - Blaise Paschal |
![]() |
| Viewing: Dev Shed Forums > Programming Languages - More > ASP Programming > Access Dates |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|