pg.ddx.io  pgsql-jdbc@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Ash Grove <ash_grv7@yahoo.com>
To: pgsql-jdbc@postgresql.org
Subject: Re: stored function, multiple queries, best practices
Date: Tue, 18 Apr 2006 11:53:51 -0700 (PDT)
Message-ID: <20060418185351.89200.qmail@web52501.mail.yahoo.com> (raw)
In-Reply-To: <444198D6.4080805@opencloud.com>



--- Oliver Jowett <oliver@opencloud.com> wrote:

> Ash Grove wrote:
> > 
> >>Why assemble a string and parse it? Why not just
> use
> >>multiple parameters 
> >>directly?
> >>-O
> > 
> > 
> > 
> > So, Oliver,  you're suggesting something like
> "call
> > myfunction('query1','query2','query3')"?
> 
> No, I'm suggesting:
> 
>    call myfunction('data value 1', 42, 1.234, 'data
> value 4')
> 
> I am assuming you know the combinations of updates
> you will need to run 
> ahead of time. If you want to run arbitary queries
> then you are probably 
> stuck with doing some parsing in the function .. but
> that is pretty nasty.
> 
> -O
> 

I know the combination of queries, but whether a
parameter has a value is unknown. Also unknow is
whether all relevant tables will get updated. If I
simply send all parameters in a defined order, the
parameter list will be kinda long and many values will
be nulls.

I can only call one function (from the application)
per transaction, right?

I don't mind doing the parsing, I was just wondering
if I was considering all options.

__________________________________________________
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 



view thread (6+ messages)  latest in thread

Message-ID: <20060418185351.89200.qmail@web52501.mail.yahoo.com>
Permalink:  ../20060418185351.89200.qmail@web52501.mail.yahoo.com/
Also on:    postgresql.org/message-id/20060418185351.89200.qmail@web52501.mail.yahoo.com

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-jdbc@postgresql.org
  Cc: ash_grv7@yahoo.com
  Subject: Re: stored function, multiple queries, best practices
  In-Reply-To: <20060418185351.89200.qmail@web52501.mail.yahoo.com>
  References: <444198D6.4080805@opencloud.com> <20060418185351.89200.qmail@web52501.mail.yahoo.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox