Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 Other Forums
 MS Access
 Passing Dates from Access to SQL Server 2000

Author  Topic 

AskSQLTeam
Ask SQLTeam Question

0 Posts

Posted - 2006-12-18 : 08:24:27
stick writes "Hi Folks
I have the user enter a start date and end date in an Access form . Since the dates will change every month, I have the dates stored in a Access table. I would like to pass the dates to the SQL Server 2000 table and return the data through a pass-through query. The stored procedure has the following code, but I'm getting an error when I set off the query. How can I pass dates from Access to SQL 2000? Any suggestions will be much appreciated. Thanks.

CREATE PROCEDURE [dbo].[usp_legal_dates] AS

SELECT TBLSYS_FBL3N_APDocTypes_2006.Doc_Type, TBLSYS_FBL3N_APDocTypes_2006.Posting_Date,

FROM TBLSYS_FBL3N_APDocTypes_2006, tbl0001_date_information

WHERE (((TBLSYS_FBL3N_APDocTypes_2006.Posting_Date) Between [tbl0001_date_information].[start_dte] And [tbl0001_date_information].[end_dte]));
GO"

SwePeso
Patron Saint of Lost Yaks

30421 Posts

Posted - 2006-12-18 : 08:26:58
You are doing a CROSS JOIN (cartesian product) query.
How do you find the information in the tbl0001_date_information table from the TBLSYS_FBL3N_APDocTypes_2006 table?
Maybe you just are experiencing a TIMEOUT since the query takes too long to run?


Peter Larsson
Helsingborg, Sweden
Go to Top of Page
   

- Advertisement -