Re: JDBC - Need to declare variables for values in insert statement - Mailing list pgsql-general

From Dave Cramer
Subject Re: JDBC - Need to declare variables for values in insert statement
Date
Msg-id CADK3HHKtX9hwwLJq__sbeEr=k_2DZz__7hvckSdK=_8bU3mtoA@mail.gmail.com
Whole thread Raw
In response to JDBC - Need to declare variables for values in insert statement  (Bob Futrelle <bob.futrelle@gmail.com>)
Responses Re: JDBC - Need to declare variables for values in insert statement  (Bob Futrelle <bob.futrelle@gmail.com>)
List pgsql-general
Bob,

Can you provide a snippet of code so I can understand what you mean by declare ?


Dave Cramer

dave.cramer(at)credativ(dot)ca
http://www.credativ.ca


On Mon, Jan 28, 2013 at 7:11 AM, Bob Futrelle <bob.futrelle@gmail.com> wrote:
Do the declare statements and insert all have to be done in one statement execute()?
That is, what is the scope of variables I declare?
I see a variety of syntax examples, some for older versions?
I'm using pg 9.2.2, so what are the rules/syntax for declaring and using variables?

Use case: I collect metadata from XML articles such as title, journalName, volume, year.  For each article I need to create a pg table record and insert the values for the various metadata items in the article.

This is my first post to this list.

Thanks,

 - Bob


pgsql-general by date:

Previous
From: c k
Date:
Subject: finding if a period is multiples of a given interval
Next
From: Paul Jones
Date:
Subject: Re: Can LC_TIME affect timestamp input?