Re: 2 Questions

From: Devrim GUNDUZ <devrim(at)commandprompt(dot)com>
To: Ramon Orticio <rporticio(at)yahoo(dot)com>
Cc: pgsql-novice(at)postgresql(dot)org
Subject: Re: 2 Questions
Date: 2005-12-23 07:49:01
Message-ID: Pine.LNX.4.63.0512230916240.7654@evim.gunduz.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-novice


Hi,

On Thu, 22 Dec 2005, Ramon Orticio wrote:

> i'm using a laptop with redhat 9 OS.
>
> 1. how do you create or transfer to another location
> postgres database aside from the initial
> PGDATA=/var/lib/pgsql/data

I think you are using RPM installation.

So, first stop postmaster. Then move the initial data cluster to another
directory you wish. Edit /etc/init.d/postgresql and change all
/var/lib/pgsql/data to the new value. Then start PostgreSQL again.

> 2. how can a jpeg or bmp file be stored in postgres.

You need to use bytea data type for that:

http://www.postgresql.org/docs/current/static/datatype-binary.html
http://www.postgresql.org/docs/current/static/largeobjects.html

Regards,
--
The PostgreSQL Company - Command Prompt, Inc. 1.503.667.4564
PostgreSQL Replication, Consulting, Custom Development, 24x7 support
Managed Services, Shared and Dedicated Hosting
Co-Authors: plPHP, plPerlNG - http://www.commandprompt.com/

In response to

  • 2 Questions at 2005-12-23 02:52:49 from Ramon Orticio

Browse pgsql-novice by date

  From Date Subject
Next Message Mag Gam 2005-12-23 15:15:39 PostgreSQL Logging
Previous Message Dario Brignardello 2005-12-23 04:51:48 Re: 2 Questions