Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Stored procedures in PL/PGSQL

2 views
Skip to first unread message

FET

unread,
Jun 14, 2004, 12:11:48 AM6/14/04
to
Hello,
I am in a bit of a conflict here. I would like to know if the stored
procedures that I write in PL/PGSQL to run on PostgreSQL 7.4.2 are
ANSI compliant. The point of asking this question is whether my stored
procedure needs to undergo a lot of change if I port it to some other
database like Oracle or MSSQL Server.

Thank you in advance,

Best regards.

Stu

unread,
Jun 14, 2004, 3:05:59 AM6/14/04
to
The logic won't change, but the syntax will. It's kind of like asking, "if
I write a program in C++ will it be easy to port to Java?" PL/PGSQL is a
language, different vendors use different languages--MS SQL Server and
Sybase use Transact-SQL (they have a shared history, that's why they use
the same language), Oracle uses PL/SQL, Firebird uses PSQL, etc.

As for ANSI compliant, ANSI added Persistent Stored Modules (SQL/PSM) in
SQL99, to address the portability issue, but I don't think any vendor has
done a complete implementation of it yet.


Stu

Christopher Browne

unread,
Jun 15, 2004, 11:11:07 PM6/15/04
to
bilari...@yahoo.com (FET) wrote:
> Hello,
> I am in a bit of a conflict here. I would like to know if the stored
> procedures that I write in PL/PGSQL to run on PostgreSQL 7.4.2 are
> ANSI compliant. The point of asking this question is whether my stored
> procedure needs to undergo a lot of change if I port it to some other
> database like Oracle or MSSQL Server.

NO system supports an "ANSI compliant" stored procedure language at
this point in time. Not PostgreSQL, not Oracle, not Microsoft SQL
Server.

It seems likely that a project may emerge in 7.6 or so to build one,
but in view of there not being _any_ compliant system, it hasn't
emerged as a priority.
--
wm(X,Y):-write(X),write('@'),write(Y). wm('cbbrowne','acm.org').
http://www.ntlug.org/~cbbrowne/x.html
Rules of the Evil Overlord #10. "I will not interrogate my enemies in
the inner sanctum -- a small hotel well outside my borders will work
just as well." <http://www.eviloverlord.com/>

0 new messages