SUPPORT / SAMPLES & SAS NOTES
 

Support

Sample 31096: How to Extract SYBASE Stored Procedures Using PROC SQL

DetailsCodeAboutRate It

This sample provides a simple way of extracting SYBASE stored procedures using PROC SQL. The code below:

  • connects to a SYBASE databse on a UNIX server
  • extracts all of the information in SYSCOMMENTS (SYBASE stores procedures here)
  • stores the procedures in a SAS variable named TEXT
  • stores the variable TEXT in a SAS table named ONE
  • disconnects from the SYSBASE database

NOTE: In retrieving all of the information stored in SYSCOMMENTS, you might find any or all of the following to be true:

  • unexpected or unwanted information
  • that the expected information has been deleted
  • that the user may not have administrative access/end user permission to access SYSCOMMENTS

Therefore, you may have to confirm access to the information and may have to do additional programming to ensure that the results are totally inclusive of what is wanted and mutally exclusive of what is not wanted.

page divider

About the Author
Bryan K. Beverly is a Software Architect and Team Leader with BAE Systems Information Technology. He has been using SAS for 20+ years and is currently supporting SAS-based systems at the Bureau of Labor Statistics. Bryan has served as a presenter and volunteer at SAS conferences for more than 10 years.


These sample files and code examples are provided by SAS Institute Inc. "as is" without warranty of any kind, either express or implied, including but not limited to the implied warranties of merchantability and fitness for a particular purpose. Recipients acknowledge and agree that SAS Institute shall not be liable for any damages whatsoever arising out of their use of this material. In addition, SAS Institute will provide no support for the materials contained herein.