RE: [PHP-DB] Struggling with PG SQL and Large Objects

From: Date: Wed, 24 Jul 2002 20:24:08 +0000
Subject: RE: [PHP-DB] Struggling with PG SQL and Large Objects
Groups: php.db 
Request: Send a blank email to php-db+get-20752@lists.php.net to get a copy of this message
CLASSIFICATION: UNCLASSIFIED It was my understanding (from a friend) that I could actually store the files in the database and thereby eliminate me having to setup permissions for folders etc.. Am I wrong? Eric Jones (Contractor) FDIC Web Enabler E-mail: jonese@hua.army.mil Office - 520-533-6628 Cell - 520-980-2136 Email Pager - 5209802136@messaging.nextel.com Direct Private Fax - 866-721-4102 -----Original Message----- From: Cornelia Boenigk [mailto:c@cornelia-boenigk.de] Sent: Wednesday, July 24, 2002 11:55 AM To: php-db@lists.php.net Subject: Re: [PHP-DB] Struggling with PG SQL and Large Objects Hi Eric > I currently can upload the file using pg_lo_import. I get back my OID which > I store in a separate table I think this is the point. PostgreSQL doesn't store the uploaded file physically in the table but only the OID which is a reference to the file which is stored in a system catalogue. > and I can remove the files using the unlink > command. To remove the file you pass the OID and PHP does the rest. It means that you do not access the uploaded file directyly but only its reference. > However for the life of me I cannot get the file to be downloaded from a > person's browsers. I keep getting an error that the file cannot be found. Because you 'see' only the reference to this file and only PostgreSQL knows the place on the harddisk where it is stored. So if you want to make the uploaded files dowloadable why don't you store them somewhere in your filesystem and put the path into your database-table? Greetings Conni -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php

« previous php.db (#20752) next »