FAQ
Once again I am having difficulties with large object. I was finally able to get all my functions and triggers straightened out but now I can't seem to open the large object. Since the last time I was able to open the large objects I have changed my operating system to Linux8. I'm using Postgresql 7.3.2 and php 4.3.1.

I found one person who has posted the same problem http://archives.postgresql.org/pgsql-general/1999-06/msg00322.php. He used the following solution:

<solution>
"After I updated to LinuxPPC R5 I had to recompile Postgres to use glibc2...
and the compiler with R5 is egcs 2.91.66. After getting some help from the
Postgres mailing list it turned out that the linux_ppc template needed to
change the compiler optimization flags from CFLAGS:-O2 to -O0. Then it ran
without problem, but before then I had many "oid" errors."
</solution>

If I need to change my linux_ppc template I probably need some help on how to do that. Or some ideas on what else I can try.

This is the code I used to try and open the large object:

<my code>
pg_exec ($db, "begin transaction");
$handle=pg_loopen($db,$row['signature'],"r"); //also tried with assigning the array value to a variable
$bitmap=pg_loreadall($handle);
echo substr($bitmap, 17);
pg_loclose($handle);
pg_exec ($db, "end transaction");
</my code>

Any help would be greatly appreciated.

Thanks.

Julie

Search Discussions

  • Patrick Hatcher at May 23, 2003 at 4:21 pm
    Try the following:
    $results = pg_query($db,"Select some_image from table");
    $row = pg_fetch_array($results);


    //Header( "Content-type: jpg");
    echo stripcslashes($row[0]);



    Patrick Hatcher
    Macys.Com


    --------+--------------------------------->
    "Juliet May" |
    <jmay@speark.com> |
    Sent by: |
    pgsql-novice-owner@post|
    gresql.org |
    05/22/2003 03:04 PM |
    --------+--------------------------------->
    ----------------------------------------------------------------------------------------------------------|
    To: <pgsql-novice@postgresql.org> |
    cc: |
    Subject: [NOVICE] Fw: Unable to open PostgreSQL large object |
    ----------------------------------------------------------------------------------------------------------|




    Once again I am having difficulties with large object. I was finally able
    to get all my functions and triggers straightened out but now I can't seem
    to open the large object. Since the last time I was able to open the large
    objects I have changed my operating system to Linux8. I'm using Postgresql
    7.3.2 and php 4.3.1.

    I found one person who has posted the same problem
    http://archives.postgresql.org/pgsql-general/1999-06/msg00322.php. He used
    the following solution:

    <solution>
    "After I updated to LinuxPPC R5 I had to recompile Postgres to use
    glibc2...
    and the compiler with R5 is egcs 2.91.66. After getting some help from the
    Postgres mailing list it turned out that the linux_ppc template needed to
    change the compiler optimization flags from CFLAGS:-O2 to -O0. Then it ran
    without problem, but before then I had many "oid" errors."
    </solution>

    If I need to change my linux_ppc template I probably need some help on how
    to do that. Or some ideas on what else I can try.

    This is the code I used to try and open the large object:

    <my code>
    pg_exec ($db, "begin transaction");
    $handle=pg_loopen($db,$row['signature'],"r"); //also tried with assigning
    the array value to a variable
    $bitmap=pg_loreadall($handle);
    echo substr($bitmap, 17);
    pg_loclose($handle);
    pg_exec ($db, "end transaction");
    </my code>

    Any help would be greatly appreciated.

    Thanks.

    Julie

Related Discussions

Discussion Navigation
viewthread | post
Discussion Overview
grouppgsql-novice @
categoriespostgresql
postedMay 23, '03 at 12:12a
activeMay 23, '03 at 4:21p
posts2
users2
websitepostgresql.org
irc#postgresql

2 users in discussion

Juliet May: 1 post Patrick Hatcher: 1 post

People

Translate

site design / logo © 2022 Grokbase