[EMAIL PROTECTED] writes:
> i'd like to write an rule which fills out some empty attrs on
> insert (w/ data from other given attrs).
You'd be better off doing this with a BEFORE INSERT trigger.
regards, tom lane
---(end of broadcast)--
hi folks,
i'd like to write an rule which fills out some empty attrs on
insert (w/ data from other given attrs).
the table structure is:
CREATE TABLE foo (start date, duration integer, endtime date);
and the rule is:
CREATE RULE foo1 AS ON INSERT TO foo WHERE new.endtime = NULL DO
INSERT
Tony,
> I've a query which needs too many time ca. 12-15 sec.
> how can i get a better perfomance?
First of all, please take this to the PGSQL-PERFORMANCE list.
Second, see this web page:
http://techdocs.postgresql.org/guides/SlowQueryPostingGuidelines
> explain select o.id from ioobeject o,dis
On Thu, 2003-06-12 at 10:24, Stephan Szabo wrote:
>
> On 12 Jun 2003, Robert Treat wrote:
>
> > Does anyone know if there is support for "IF x OR y THEN" syntax in
> > plpgsql? The docs just say IF [boolean expression] then. which loosely
> > interpreted could allow for an OR, but I couldn't seem
On Thu, 12 Jun 2003, Ludwig Lim wrote:
> I would like to ask the following questions:
> a) Are foreign key constraint triggers guaranteed to
> execute first before any ordinary "BEFORE
> INSERT/UPDATE/DELETE" trigger is executed? (This is
> assuming that the foreign keys are declared as "NOT
On 12 Jun 2003, Robert Treat wrote:
> Does anyone know if there is support for "IF x OR y THEN" syntax in
> plpgsql? The docs just say IF [boolean expression] then. which loosely
> interpreted could allow for an OR, but I couldn't seem to get it to
> work. TIA,
Can you give a full example of wha
hello,
I've a query which needs too many time ca. 12-15 sec.
how can i get a better perfomance?
my table have less than 2300 rows.
thanks in advance
tony
explain select o.id from ioobeject o,dist_vertron v where
macro_lid=1123 and (o.id=v.id) and (o.deleted<>'1') and
(o.status='acti
Does anyone know if there is support for "IF x OR y THEN" syntax in
plpgsql? The docs just say IF [boolean expression] then. which loosely
interpreted could allow for an OR, but I couldn't seem to get it to
work. TIA,
Robert Treat
--
Build A Brighter Lamp :: Linux Apache {middleware} PostgreSQL
Achilleus Mantzios <[EMAIL PROTECTED]> writes:
> On Thu, 12 Jun 2003, A. Van Hook wrote:
>> When updating from 7.2.3 to 7.3.3 we have lost the ability to see the
>> passwords in pg_shadow. Is there a way to decrypt the passwords?
> But you still can do
> ALTER USER foo UNENCRYPTED password 'bar'
On Thu, Jun 12, 2003 at 02:37:00PM +0200, Christoph Haller wrote:
> >
> > Like "Tell me how much i spent between the 4th and the 7th og this
> month
> > ?" uses 4 and 7 as arguments, but need to fetch the datas in the
> > database.
> > Clear enough ? :-)
> Yes.
> >
> > What do you mean by table fun
>
> Like "Tell me how much i spent between the 4th and the 7th og this
month
> ?" uses 4 and 7 as arguments, but need to fetch the datas in the
> database.
> Clear enough ? :-)
Yes.
>
> What do you mean by table function ?
Table functions are aka SetReturningFunctions.
Refer to
http://techdocs.pos
[EMAIL PROTECTED] wrote:
>
> On Thu, Jun 12, 2003 at 13:21:01 +0200,
> Marco Vezzoli <[EMAIL PROTECTED]> wrote:
> > Hi everybody,
> > I'm sorry if this topic has already been explained, but the search
> > engine at archives.postgresql.org shows me 10 pages of results but
> > without any link (!)
On Thu, Jun 12, 2003 at 02:10:06PM +0200, Christoph Haller wrote:
> > > > These values are not taken in a table, but put in directly.
> >
> > I guess i wasn't clear enough.
> > "my_function" here is a function which calculate some results about
> some
> > datas from the database.
> > Example : a fu
Hi:
I would like to ask the following questions:
a) Are foreign key constraint triggers guaranteed to
execute first before any ordinary "BEFORE
INSERT/UPDATE/DELETE" trigger is executed? (This is
assuming that the foreign keys are declared as "NOT
DEFERRABLE")
b) Is "varchar" (without upper l
On Thu, Jun 12, 2003 at 07:09:29AM -0500, Bruno Wolff III wrote:
> On Thu, Jun 12, 2003 at 13:50:27 +0200,
> David Pradier <[EMAIL PROTECTED]> wrote:
> >
> > I guess i wasn't clear enough.
> > "my_function" here is a function which calculate some results about some
> > datas from the database.
>
> > > These values are not taken in a table, but put in directly.
>
> I guess i wasn't clear enough.
> "my_function" here is a function which calculate some results about
some
> datas from the database.
> Example : a function which would calculate the sum of the money (which
> would be stored in t
On Thu, Jun 12, 2003 at 13:50:27 +0200,
David Pradier <[EMAIL PROTECTED]> wrote:
>
> I guess i wasn't clear enough.
> "my_function" here is a function which calculate some results about some
> datas from the database.
> Example : a function which would calculate the sum of the money (which
> wou
On Thu, Jun 12, 2003 at 13:21:01 +0200,
Marco Vezzoli <[EMAIL PROTECTED]> wrote:
> Hi everybody,
> I'm sorry if this topic has already been explained, but the search
> engine at archives.postgresql.org shows me 10 pages of results but
> without any link (!).
> I'm using postgres 7.1.3 on Solaris
On Thu, Jun 12, 2003 at 01:16:27PM +0200, Christoph Haller wrote:
> >
> > i ran today in a problem when doing some (i mean too much for me)
> advanced sql...
> >
> > What i want to do is something like this:
> >
> > SELECT
> > my_var1,
> > my_var2,
> > my_function(my_var1, my_var2
On Thu, Jun 12, 2003 at 11:19:14 +0200,
David Pradier <[EMAIL PROTECTED]> wrote:
>
> In short, i want to calculate the result of the function my_function for
> some values of my_var1, cross by some values of my_var2.
> These values are not taken in a table, but put in directly.
> They are a lot,
On Thu, 12 Jun 2003, A. Van Hook wrote:
> When updating from 7.2.3 to 7.3.3 we have lost the ability to see the
> passwords in pg_shadow. Is there a way to decrypt the passwords?
The default case (with md5 method in pg_hba.conf) is encrypted passwds.
But you still can do
ALTER USER foo UNENCRY
When updating from 7.2.3 to 7.3.3 we have lost the ability to see the
passwords in pg_shadow. Is there a way to decrypt the passwords?
thanks
--
A. R. Van Hook
Honeywell Federal Manufacturing & Technologies
IT System Engineer
City of Lake Lotawana MO
Mayor
---
Hi everybody,
I'm sorry if this topic has already been explained, but the search
engine at archives.postgresql.org shows me 10 pages of results but
without any link (!).
I'm using postgres 7.1.3 on Solaris 8; I would like to do some query of
this form
SELECT * FROM table WHERE (attribute1,attribut
It's been a while since I've done much SQL..
. I'm wondering which of these two queries is faster (both get the
same result)?
. Which one is more correct? Does it even matter or are they the
same? The first one reads easier to me.
. What's the difference between "InitPlan" and "SubPlan"?
exp
>
> i ran today in a problem when doing some (i mean too much for me)
advanced sql...
>
> What i want to do is something like this:
>
> SELECT
> my_var1,
> my_var2,
> my_function(my_var1, my_var2)
> FROM (
> SELECT
> '1',
> '2',
> '3
Hi everybody,
i ran today in a problem when doing some (i mean too much for me) advanced sql...
What i want to do is something like this:
SELECT
my_var1,
my_var2,
my_function(my_var1, my_var2)
FROM (
SELECT
'1',
'2',
26 matches
Mail list logo