Return-Path: owner-postman Received: from localhost.Berkeley.EDU (localhost.Berkeley.EDU [127.0.0.1]) by nobozo.CS.Berkeley.EDU (8.6.10/8.6.3) with SMTP id SAA13858 for postgres-redist; Sat, 5 Aug 1995 18:23:15 -0700 Resent-From: POSTGRES mailing list Resent-Message-Id: <199508060123.SAA13858@nobozo.CS.Berkeley.EDU> X-Authentication-Warning: nobozo.CS.Berkeley.EDU: Host localhost.Berkeley.EDU didn't use HELO protocol Sender: owner-postman@postgres.Berkeley.EDU X-Return-Path: owner-postman Received: from tristero.io.com (tristero.io.com [199.170.88.11]) by nobozo.CS.Berkeley.EDU (8.6.10/8.6.3) with ESMTP id SAA14023 for ; Sat, 5 Aug 1995 18:23:13 -0700 Received: from dialup-16.austin.io.com (dialup-12.austin.io.com [199.170.89.50]) by tristero.io.com (8.6.12/8.6.12) with SMTP id UAA23243; Sat, 5 Aug 1995 20:22:43 -0500 Date: Sat, 5 Aug 1995 20:22:43 -0500 Message-Id: <199508060122.UAA23243@tristero.io.com> X-Sender: mskc@mail.io.com Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" To: "David S. Kenzik" , postgres@postgres.Berkeley.EDU From: mskc@io.com (Casey Claiborne) Subject: Re: Problem using external SQL calls. X-Mailer: Resent-To: postgres-redist@postgres.Berkeley.EDU Resent-Date: Sat, 05 Aug 95 18:23:15 -0700 Resent-XMts: smtp How were you able to use SQL statements. What version do you have? I would always have to use something like "retrieve (person.all)" to get the data that you have. I, myself, used a "C" interface and I was able to get data back that way. There are examples (similar to the one you have below, except written in "C") in the directory holding sample code. Also, if I remember correctly, you can also check "manual.ps" or "manual.txt" or one of these files that hold the references to the types of commands that are available as a part of Postgres, there is an area that discusses the "retrieve" command. There is also some "C" code that goes with the explanation. That part helped me out a *whole* lot - there were a lot of examples. I know that you are using perl. I was just providing another option. Good Luck :-) Casey At 04:01 PM 8/5/95, David S. Kenzik wrote: > >I am using Postgre95 beta 0.02 along with PGperl5 in a Solaris 2.4 >environment. > >I have created a database called 'dbtest', set up a couple fields, and >entered 1 row of data. > >Monitor output follows: > >---------------------- >bash$ monitor dbtest >Welcome to the POSTGRES95 terminal monitor > >Go >* select * from person; > >Query sent to backend is "select * from person;" >----------------------------- >| name | age | >----------------------------- >| dave | 10 | >----------------------------- > >--------------------- > >I have a script written in perl 5 using PGpm that doesn't return any >value, except 'PGblank'. The code follows: > >--------------------- > >#!/usr/bin/perl >use Pg; >$db="dbtest"; >PQsetdb($db); >$query="select * from person"; >$result=PQexec($query); >print "$result\n"; > >And the results: > >bash$ ./dbtest2 >Pblank > >----------------- > >Any insight would be greatly appreciated, as it's been a long couple of >days. :) > > >Regards, > >.===========================================================================. >| David S. Kenzik - Project Director - OneNet Communications : dsk1@one.net | >+===========================================================================+ >| Current Projects: finger projects@one.net WWW: http://www.one.net | >| Information: info@one.net Phone: (513) 326-6000 | >=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= > > >============================================================================== > To add/remove yourself to/from the POSTGRES mailing list: send mail with > the subject line ADD or DEL to "postgres-request@postgres.Berkeley.EDU". > If this fails, send mail to "post_questions@postgres.Berkeley.EDU" and > a human will deal with it. DO NOT post to the "postgres" mailing list. >============================================================================== > URL: http://s2k-ftp.CS.Berkeley.EDU:8000/postgres/ > > Casey Claiborne mskc@io.com One must note the importance of setting reasonable and achievable goals for "If you aim for nothing, you'll hit it every time" -Theodore Roosevelt ============================================================================== To add/remove yourself to/from the POSTGRES mailing list: send mail with the subject line ADD or DEL to "postgres-request@postgres.Berkeley.EDU". If this fails, send mail to "post_questions@postgres.Berkeley.EDU" and a human will deal with it. DO NOT post to the "postgres" mailing list. ============================================================================== URL: http://s2k-ftp.CS.Berkeley.EDU:8000/postgres/