Subject: Installing pgperl

From: Eric P Dean <[email-masked]>
Date: Thu, 01 Sep 1994 16:33:09 CDT

I am still trying to get pgperl installed on my DEC 5000/133 running
Ultrix 4.3a with Postgres 4.2 and pgperl 4.036.

I ran the testlibpq.pl program and got a segmentation fault where it
starts working with portals.  The output from testlibpq.pl and a section
of code from testlibpq.pl follows.
Does anyone have any ideas as to why it may have bombed?

Thank you

Eric Dean
Curator, Visual Resources Collection
College of Design, Iowa State University

It looks like it blew-up on "@names = &PQpnames (0);" in the subroutine
test_rest of testlibpq.pl

sub test_rest {
    printf("Opening 2 portals:\n");
    &doPQexec ("begin");
    &doPQexec ("retrieve portal eportal (person.all)");
    &doPQexec ("fetch all in eportal");
    &doPQexec ("retrieve portal fportal (person.all)");
    &doPQexec ("fetch all in fportal");
    printf("Number of portals open: %d\n", &PQnportals(0));
    @names = &PQpnames (0);
    print "Portal names: ", join(', ',@names), ".\n";
    $p = &PQparray ("eportal");
    printf("Portal eportal %s asynchronous.\n",&PQrulep($p) ? "is" : "is not");
    printf("Portal eportal has %d tuples.\n",&PQntuples($p));
    printf("Portal eportal has %d instances.\n",&PQninstances($p));
    printf("Portal eportal has %d groups.\n",&PQngroups($p));

->pgperl /local/postgres/src/contrib/pgperl/testlibpq.pl
Destroying database pgperltest
Creating database pgperltest
Accessing database pgperltest

Creating relation person:
query = create person (name = char16, age = int4, location = point)

Relation person before appends:
New tuple group:
name           age            location       

Appending to relation person:
query = append person (name = "fred", age = 50, location = "(50,10)"::point)
query = append person (name = "fred", age = 60, location = "(60,10)"::point)
query = append person (name = "fred", age = 70, location = "(70,10)"::point)
query = append person (name = "fred", age = 80, location = "(80,10)"::point)
query = append person (name = "fred", age = 90, location = "(90,10)"::point)
query = append person (name = "fred", age = 100, location = "(100,10)"::point)
query = append person (name = "fred", age = 110, location = "(110,10)"::point)
query = append person (name = "fred", age = 120, location = "(120,10)"::point)
query = append person (name = "fred", age = 130, location = "(130,10)"::point)
query = append person (name = "fred", age = 140, location = "(140,10)"::point)
query = append person (name = "fred", age = 150, location = "(150,10)"::point)

Relation person after appends:
New tuple group:
name           age            location       
fred           50             (50,10)        
fred           60             (60,10)        
fred           70             (70,10)        
fred           80             (80,10)        
fred           90             (90,10)        
fred           100            (100,10)       
fred           110            (110,10)       
fred           120            (120,10)       
fred           130            (130,10)       
fred           140            (140,10)       
fred           150            (150,10)       

Testing copy:

Relation person after copy:
New tuple group:
name           age            location       
fred           50             (50,10)        
fred           60             (60,10)        
fred           70             (70,10)        
fred           80             (80,10)        
fred           90             (90,10)        
fred           100            (100,10)       
fred           110            (110,10)       
fred           120            (120,10)       
fred           130            (130,10)       
fred           140            (140,10)       
fred           150            (150,10)       
bill           21             (1,2)          
bob            61             (3,4)          
sally          39             (5,6)          

Testing other things:
Opening 2 portals:
Number of portals open: 2
Segmentation fault
->

==============================================================================
   To add/remove yourself to/from the POSTGRES mailing list: send mail with 
   the subject line ADD or DEL to "[email-masked]"

   If this fails, send mail to "[email-masked]" and
   a human will deal with it.  DO NOT post to the "postgres" mailing list.
==============================================================================