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
 SQL Server 2005 Forums
 Other SQL Server Topics (2005)
 Sending Vars from Access 2000 to SQL 2005 usp

Author  Topic 

HawkSaw
Starting Member

1 Post

Posted - 2009-08-11 : 12:33:46
Hi. I've been learning about SQL Server 2005 stored procedures, and understand the concepts. Same with Access 2000. I'm quite good at the Access front end. I've linked the user stored procs to Access 2000. What I don't get, is how to collect user input on the Access front-end form and pass it to SQL usp so it can select a smaller range of records and return them to the front end. It's easy in Access - link the two tables via the Primary/Foreign key. I need to do the same thing via usp.

Can someone give me sample VBA code and/or SQL usp code that will pass these vars and return the result to Access? Note I'm trying to sort over 2 million records to return results of about 300. Access pulls all of them, and that's a lot of network traffic.

Thanks so much.

sample: I have a view in SQL that pulls all materials for all jobs (the 2 mil records). I want to pull just the materials for one job, selected by combo box (JobID) in an Access form (Form!frmJob!PickJobID). Goal: to pass the selected JobID in the combo box to the usp, have it find matching records and return them to the front end for display in Access. Sorry if that's redundant. Just want to be clear.

M

I am but mad NNW
   

- Advertisement -