[AccessD] Reports, temp tables and stored procedures

Rocky Smolin - Beach Access Software bchacc at san.rr.com
Tue Apr 22 15:00:39 CDT 2003


Reports, temp tables and stored proceduresTim:

I have apps with a lot of >= and <= type parameters on the form which calls the report.  What I have moved to is setting up a filter in SQL in the _Open event of the report.  Alternatively I sometimes assemble the SQL statement and make that the record source of the report.

I also give the user combo boxes to select fields for primary, secondary, and tertiary sort which you can also set in code in the OnOpen event of the report.

I can post some code examples if you need them.

Rocky

  ----- Original Message ----- 
  From: Pain, T. (Tim) 
  To: accessd at databaseadvisors.com 
  Sent: Tuesday, April 22, 2003 7:23 AM
  Subject: [AccessD] Reports, temp tables and stored procedures


  I have a number of reports that are driven from forms that let the user input the report parameters, the code behind the form first clears a temporary work table, then builds and runs a query based on the forms parameters and then in code loops through this temp table updating other fields not populated by the first query. At the end of this it outputs a report based on the temp work table.

  Having recently moved the backend to SQL Server and I think I ought to be able to re-write the above to use #temp tables and stored procedures, but I have no real idea where to start. I reasonalby OK writing simple stored procedures but it's the creating and initial populating the #temp table, then looping back through it with further updates and then using the #temp table as the basis for the report that has me puzzled.

  Does anybody have a example they could let me have to get me started please? 

  Many thanks 
  Tim Pain 
  Akzo Nobel Surface Chemistry Ltd 
  <MailTo:Tim.Pain at AkzoNobel.com> 








------------------------------------------------------------------------------


  _______________________________________________
  AccessD mailing list
  AccessD at databaseadvisors.com
  http://databaseadvisors.com/mailman/listinfo/accessd
  Website: http://www.databaseadvisors.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://databaseadvisors.com/pipermail/accessd/attachments/20030422/b6cf1a88/attachment-0001.html>


More information about the AccessD mailing list