From: | Soma Interesting <dfunct(at)telus(dot)net> |
---|---|
To: | pgsql-general(at)postgresql(dot)org |
Subject: | PL/pgSQL compatibility? |
Date: | 2000-12-08 21:35:11 |
Message-ID: | 5.0.0.25.0.20001208130016.00bd4008@pop.telus.net |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
I'm looking to join the camp of people who believe data logic should be
handled within the database(postgreSQL) and not the client code(php). I
realize there are pros and cons to this approach but its something I want
to explore and be able to take advantage of where applicable. However most
of the elements involved in doing this I know little about, ie: stored
procedures, triggers, referential integrity, constraints, etc.
One con, I understand, would be ability to migrate to another DBMS. If I
were to use PL/pgSQL for my stored procedures - is this language a standard
across DBMS? I'm not expecting this since most DBMS can't seem to follow
SQL standards with simple things like dates or wild-cards.
. . . .
Another, more specific question: I'd like to know how to make two tables in
PostgreSQL with a relationship between them so that when the parent row is
removed from one table, its children in the other table will also be
removed by PostgreSQL. I don't even know how to specify the foreign key. :)
Conceptually I understand (I believe). I'm just no sure how to define this
within PostgreSQL
I've done some searching through the on-line postgreSQL manual - in hopes
to find a chapter in it akin to "referential integrity", but no such luck.
Its possible I'm confusing the terminology.
So, if someone can point me towards some additional information on this,
that'd be appreciated.
. . . .
Furthermore, my need for information on this topic will obviously goes
beyond this one issue - can someone recommend either an on-line resource to
advanced data modelling and / or database design or books worth purchasing
on the topic.
Summary of questions:
1) How cross database is PL/pgSQL?
2) How to define foreign -> primary key relationship where foreign key
records are deleted
3) recommended readings on any of the above.
- - - - - - -
- - - - -
WARNING: Some experts believe that use of any keyboard may cause serious
injury.
Consult Users Guide.
dfunct(at)telus(dot)net
From | Date | Subject | |
---|---|---|---|
Next Message | Tim Barnard | 2000-12-08 22:07:45 | Re: pgsql and C++ compiling question |
Previous Message | Larry Rosenman | 2000-12-08 21:32:53 | Re: pgsql and C++ compiling question |