JDBC - Need to declare variables for values in insert statement

From: Bob Futrelle <bob(dot)futrelle(at)gmail(dot)com>
To: pgsql-general(at)postgresql(dot)org
Subject: JDBC - Need to declare variables for values in insert statement
Date: 2013-01-28 12:11:35
Message-ID: CAOsWdXoc+rt8g8A-TLm1-sjHdydHvyRdzNGu5q_hBjTzpccJrQ@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

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

Responses

Browse pgsql-general by date

  From Date Subject
Next Message c k 2013-01-28 13:24:51 finding if a period is multiples of a given interval
Previous Message Leif Jensen 2013-01-28 10:19:42 Rules on views - Changes from 8.4 to 9.1 ?