DATA Step, Macro, Functions and more

Version Controlling of SAS Program

Reply
Contributor
Posts: 60

Version Controlling of SAS Program

Hi All,

Is there any way to have version control in SAS Programs.

1. An automatic time stamp should be placed in the top of the Program (in header Part) whenever the user changes the code and closing the program from session.

2. In a team anyone can the open the program and do some modification in the absence of the Owner of the program for that we have to include the User name along with the time stamp to identify the person who modified.

3. Suppose in a Project environment anyone can open any program, but if user01 opens and editing the DEMO.SAS program and at the same time user02 wants to open the same program it should be read only for user02.

If possible

4. Is there any way to take the Last modified version of the program for ex: Modified on 01 AUG 2008 4:53 PM or even earlier
Super Contributor
Posts: 394

Re: Version Controlling of SAS Program

Posted in reply to Sudhakar_A
I would think that any of the popular version control systems out there would suffice. CVS (http://en.wikipedia.org/wiki/Concurrent_Versions_System) has been around for a long time. Subversion (http://en.wikipedia.org/wiki/Subversion_(software)) is newer but extremely popular. Both are free, have enormous user communities, and are well-documented.
New Contributor
Posts: 2

Re: Version Controlling of SAS Program

Posted in reply to Sudhakar_A
With CVS, you could include the CVS header and log statements and SAS would recognized them as comments:
/*$Header$*/
/*$Log$*/

Subversion keywords seem to be surrounded by dollar signs, which SAS doesn't seem to recognize as comments:
$ID$
$Revision$

Is there a way for SAS to recognize the Subvervsion keywords as comments?

Thanks in advance
Super Contributor
Posts: 394

Re: Version Controlling of SAS Program

Just surround the keywords with comment markers. Subversion will recognize them and do the substitution as always.

/* $Id$ */
/* $Revision$ */

http://svnbook.red-bean.com/en/1.5/svn-book.html
New Contributor
Posts: 2

Re: Version Controlling of SAS Program

Great - thank you!
Ask a Question
Discussion stats
  • 4 replies
  • 175 views
  • 0 likes
  • 3 in conversation