libpq++ library - Mailing list pgsql-general

From Summer
Subject libpq++ library
Date
Msg-id Pine.SGI.3.96.980706184206.21838B-100000@waimea.cs.unm.edu
Whole thread Raw
In response to Re: [GENERAL] Alphabetical sorting...  (Chris Johnson <cmj@inline-design.com>)
List pgsql-general
I am a psql beginner and am using the libpq++ library to write a series of
programs that access a database.

My database is working well, my problem is with:
PgCursor::Declare

PgCursor CourseData(data, "Student_course_record_portal");

I create this cursor and am able to successfully do:
CourseData.Declare(course_query.c_str())
CourseData.Fetch()
CourseData.GetValue(i, course_fnum)

It is when I want to repeat this process that I have problems.

I want to Declare a different string for the same PgCursor.
and then fetch from this new string's value (a select stmt)

If I just do one or the other things work correctly, but the repeating of
Declare and Fetch cause:
NOTICE:  (transaction aborted): queries ignored until END
which then leads to the Fetch not working.....

I have also tried to just create a different PgCursor -
but this leads to an error
about not being in the default state.

Does anyone know of a fix - or am I making a stupid mistake?

Thank you for your time,
Summer

<<>><<>><<>><<>><<>><<>><<>><<>><<>><<>><<>><<>><<>><<>><<>><<>><<>><<>><<>>
Summer                                  Office: Ferris Engineering
CS151 Course Coordinator                Phone:  277-9424
Student Computer Consultant             e-mail: summerd@unm.edu
University of New Mexico            summerd@cs.unm.edu
<<>><<>><<>><<>><<>><<>><<>><<>><<>><<>><<>><<>><<>><<>><<>><<>><<>><<>><<>>




pgsql-general by date:

Previous
From: lynch@lscorp.com (Richard Lynch)
Date:
Subject: Re: [GENERAL] Alphabetical sorting...
Next
From: lynch@lscorp.com (Richard Lynch)
Date:
Subject: translate "bug"?