Solved

Need help creating a Sql Stored Proc and executing it from Access

Posted on 2011-03-14
3
352 Views
Last Modified: 2012-05-11
I have an access front end linked to some tables in a Sql Server 2005 back end.  I would like to create a stored procedure in Sql Server that appends all records from Table 1 into Table 2.  I then need to be able to execute that Stored Procedure from my Access front end.  My access front end is linked to Table 2.  I have never done this before and need some help with the sp syntax and how to call it.   Thanks.
0
Comment
Question by:snyperj
  • 2
3 Comments
 
LVL 2

Accepted Solution

by:
viscogel earned 500 total points
ID: 35127755
0
 

Author Comment

by:snyperj
ID: 35129814
hmmm... i created two stored procedures.  One to delete all the records from my temporary table and then one to append new data into it.    I am then calling them from a pass through separate pass through queries using 'exec' and the sp name.

I can delete records from the table ok... (So I am able to "exec" from the access side...)  however whenever I try to run the sp that appends new records I get the error shown.

If I run the sp from SQL, it runs no problem and quickly.
error.jpg
0
 

Author Closing Comment

by:snyperj
ID: 35133186
worked through it... thanks for the link.
0

Featured Post

How to improve team productivity

Quip adds documents, spreadsheets, and tasklists to your Slack experience
- Elevate ideas to Quip docs
- Share Quip docs in Slack
- Get notified of changes to your docs
- Available on iOS/Android/Desktop/Web
- Online/Offline

Join & Write a Comment

Most if not all databases provide tools to filter data; even simple mail-merge programs might offer basic filtering capabilities. This is so important that, although Access has many built-in features to help the user in this task, developers often n…
Experts-Exchange is a great place to come for help with solutions for your database issues, and many problems are resolved within minutes of being posted.  Others take a little more time and effort and often providing a sample database is very helpf…
Learn how to number pages in an Access report over each group. Activate two pass printing by referencing the pages property: Add code to the Page Footers OnFormat event to capture the pages as there occur for each group. Use the pages property to …
What’s inside an Access Desktop Database. Will look at the basic interface, Navigation Pane (Database Container), Tables, Queries, Forms, Report, Macro’s, and VBA code.

760 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

18 Experts available now in Live!

Get 1:1 Help Now