Re: Track changes to function code

From: Jacob Bunk Nielsen <jacob(at)bunk(dot)cc>
To: <pgsql-general(at)postgresql(dot)org>
Subject: Re: Track changes to function code
Date: 2014-07-21 12:36:21
Message-ID: spamdrop+87d2cy99dm.fsf@atom.bunk.cc
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Rebecca Clarke <r(dot)clarke83(at)gmail(dot)com> writes:

> At present when a function is being edited we keep note of when and
> by who within comments in the function's code.

That sounds cumbersome.

> Is there, or can anyone recommend, any open source software that
> tracks function activity when it comes to edits (not executions)? 

How about keeping the code outside of the database in a VCS such as git,
Subversion or whatever you are used to using for other code projects?

That will also make it possible easily go back to previous versions if
you should need to some day.

You simply put your functions in one or more .sql files that you
version control using e.g. git.

Once you have written your functions you can put them in you database
using:

psql -f myfile.sql

--
Jacob

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Pavel Stehule 2014-07-21 13:12:40 Re: Track changes to function code
Previous Message Rebecca Clarke 2014-07-21 12:25:50 Track changes to function code