Problems with large objects

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]



  Hi there, I am having a REAL problem with large objects. I insert them into the database, with no problems, but when it is time of reading (the large object is a PDF file) I have a file with a carriage return at the end, so, I get corrupted data !

  The code I use is this:
 

        $paper_row = pg_Fetch_row($paper, 0);
                @pg_Exec($conn,"begin");
                $image_oid=$paper_row[0];
                $fh=@pg_loopen($conn,$image_oid,"r");
                @pg_loreadall($fh);
                @Pg_loClose ($fh);
                @pg_exec("commit");


  Thanks for your attention.

  Best regards.

--
        Luis Martins
  Eng. Sistemas e Computacao
   Servicos de Informatica
   Universidade do Algarve
 


[Index of Archives]     [Postgresql General]     [Postgresql Admin]     [PHP Users]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Databases]     [Yosemite Backpacking]     [Postgresql Jobs]

  Powered by Linux