On Fri, Oct 17, 2003 at 03:10:03PM +, Edwin Quijada wrote:
> Where can I find examples to accesing postgres with perl.
if you have DBD::Pg and DBI, check out their respective
manpages. that's the easy way to get into postgres from perl.
as far as having perl available from inside postgres, c
Marshall Spight wrote:
> "Daniel Åkerud" <[EMAIL PROTECTED]> wrote in message
> 007101c13b96$834e8960$c901a8c0@automatic100">news:007101c13b96$834e8960$c901a8c0@automatic100...
> >
> > Anyway I called it "uzer" now. Maybe usr is better... users is out of the
> > question since table names are supp
i'm trying to get postgresql to listen on 127.0.0.1:5432,
192.168.1.1:5432 but not on xx.yy.zz.qq:5432 --
from the admin guide i see:
VIRTUAL_HOST (string)
Specifies the TCP/IP hostname or address on which the
postmaster is to listen for connections from c
On Fri, Aug 24, 2001 at 09:53:00PM +, uncleleo wrote:
> I am attemping to create multiple databases with Postgresql ver. 7.0.3
> running on Mandrake 8.0 rpm. The tool that I am using is Pgadmin ver 7.1.0.
>
> Can someone tell me how I can connect to different databases in a single
> select s
in looking for a way to abstract the generation of formatting
methods based on field type (dates=center & formatted; numerics
right-flush; text left-flush, etc) for web pages i've run into a
gap i don't know how to close:
using perl (5.005_03) and DBI (1.13, which refers to
DBD/Pg
On Wed, Aug 29, 2001 at 10:44:56AM +0200, Stan wrote:
> How can I change the sequence of characters in PostgreSQL character indexes
create index some_ix
on some_tbl ( substr(some_fld,3,1) || substr(some_other_fld,12,5) );
but if you look hard enough, you'll usually find a better model
by
On Wed, Aug 15, 2001 at 05:11:28PM -0700, Scott Holmes wrote:
> It would seem that my database has unseen garbage in the field being queried.
> On further testing I find that
>
> select *
> from people
> where peopcode LIKE 'AB%AH%'
> order by peopcode;
>
> works, however
>
> select *
> f
On Tue, Aug 21, 2001 at 10:25:35AM +0200, Tony Grant wrote:
>
> > > For example, say I've got a postgresql database of client information
> > > (names, addresses, etc.), and I want to use this information to generate
> > > envelopes for mailouts. As far as my understanding goes, such
> > > funct
on Technology Providers
-Original Message-
From: will trillich [mailto:[EMAIL PROTECTED]]
Sent: 24 July 2001 06:36
To: [EMAIL PROTECTED]
Subject: hmm. stage one of four -- where's the rest?
i'm hoping to install your odbc connection package so
my os 8.1 powermac can connect to my debian
i have a solution using RULES and PLGPSQL functions (instead of
triggers) for insert-unless-found, using perl lingo:
# perlish pseudoCode
unless (select(tbl.fld == val)) { insert tbl.fld = val };
i'd love to hear the skinny on why the following is a bad idea,
which i presume it i
On Wed, Jul 18, 2001 at 12:06:33PM -0400, Tom Lane wrote:
> Martijn van Oosterhout <[EMAIL PROTECTED]> writes:
> > Seems to usually happen during vacuums. Should I be worried?
>
> Nope. You're just watching VACUUM notify the other backends that it's
> moving system catalog entries around.
this
Subject: Cron <[EMAIL PROTECTED]> [ -x /usr/lib/postgresql/bin/do.maintenance ] &&
/usr/lib/postgresql/bin/do.maintenance -a
X-Cron-Env:
X-Cron-Env:
X-Cron-Env:
X-Cron-Env:
Sender: CronDaemon <[EMAIL PROTECTED]>
Date: Wed, 18 Jul 2001 04:00:33 -0500
NOTICE: RegisterSharedInvalid: SI buffer
On Wed, Jul 18, 2001 at 11:57:35AM -0400, Tom Lane wrote:
> will trillich <[EMAIL PROTECTED]> writes:
> > $ psql -V
> > No database specified
>
> This seems awfully fishy, since (a) there is no such error message
> anywhere in 7.1, and (b) I don't get that be
On Tue, Jul 17, 2001 at 09:26:02PM +0200, Peter Eisentraut wrote:
> will trillich writes:
>
> > in the old days (7.0.3) i could list databases via
> >
> > psql -l
> >
> > but these days (7.1) i must
> >
> > psql -l [-d] nameOfADatabaseFrom
On Wed, Jul 04, 2001 at 02:56:06PM +0100, Richard Huxton wrote:
> From: "Johan Björk" <[EMAIL PROTECTED]>
>
> > Have a little problem with bit operaitions that I cannot find the answer
> to on the Internet. Have been searching through the archives but no result.
> >
> > In MySQL you can have a IN
after upgrading from 7.0.3 to 7.1 i find some snags in the
indexing and 'references' --
ERROR: UNIQUE constraint matching given keys for referenced table "d_language" not
found
so i try going to /usr/share/doc/postgresql-doc/html/user
to find the 'create table' documentation...
where exactly
On Tue, May 29, 2001 at 12:56:56PM +0530, Kapil Tilwani wrote:
> Though I found extensive documentation on the Postgres
> web-site for Postgres, where can I get a similarly extensive
> docket for Linux... please... including how to make linux
> behave as a server for Windows clients... remember, t
On Wed, Jun 27, 2001 at 02:24:24AM +0100, Ryan Mahoney wrote:
> *Disclaimer* - me sleepy, no guarantee of intelligebility or relevence ;)
>
> First thing that strikes me is that you should use varchar datatype for
> almost all of your fields with the exception of the body within posts.
>
> If I
On Tue, Jun 12, 2001 at 05:33:02PM +0100, Dan wrote:
> Hello,
>
> I have a small php script to log web access that writes to a psql database.
> The error I get everytime I do a refresh is:
> Warning: PostgreSQL query failed: ERROR: Cannot insert a duplicate key into
> unique index session_pkey in
On Fri, Jun 15, 2001 at 11:18:40AM +0100, Mark wrote:
> How would I go about moving or copying data between databases on the same
> server, without actually doing a dump ? Using an SQL statement,
> something like:
>
> SELECT dbase_a.sometable.somefield
> INTO dbase_b.sometable
> FROM dbase_a
On Wed, Jun 13, 2001 at 07:25:46PM +0200, Nils Zonneveld wrote:
>
>
> Carfield Yim wrote:
> >
> > I am a new user of PostgreSQL dbms, how can I check how many tables
> > avaliable at that database?
>
> To get a list of tables through SQL:
>
> SELECT tablename FROM pg_tables WHERE tablename N
On Sat, Jun 16, 2001 at 12:41:57AM -0400, Alex Pilosov wrote:
> Actually, I just tried your original example, and it worked for me:
> use Apache::Session::Postgres;
>
> #if you want Apache::Session to open new DB handles:
>
> tie %hash, 'Apache::Session::Postgres', $id, {
Alex Pilosov wrote:
>
> On Sat, 16 Jun 2001, will trillich wrote:
>
> > the manpages for Apache::Session::DBI still say that it
> > uses Apache::Session::DBIStore for its grunt work. whereas
> You still have the old manpages (and probably old scripts).
> CPAN's
On Mon, Jun 04, 2001 at 11:16:40AM -0400, Jim Mercer wrote:
> would it be possible for me to create a template2 and have some arbitrary
> database use it instead of template1?
>
> the reason i ask this is that it would be useful to have something to the
> effect of:
>
> database access startup f
On Tue, Jun 05, 2001 at 01:17:00AM +0200, Rasmus Resen Amossen wrote:
> > Problem is not 'where'. Views in Postgresql doesn't allows you insert,
> > update or delete unless you define especila rules that explain Postgresql
> > what to do in each case.
> > Look Postgresql programming manual. Yo
get install postgresql-doc) the objects you can grant and
revoke priviliges from tables, but not databases.
you can specity 'public' meaning "everyone at large that's not
specifically mentioned in a contrary access rule" but it looks
like you'll need to iterate for each
On Sun, May 06, 2001 at 02:59:31AM +0200, Morten Primdahl wrote:
> > \d tbl_c_id_seq
> >
> > if it is not there, you can create it yourself
>
> Thanks, the sequence was not there. Just puzzled me that
> when creating tbl_c, I get:
>
> test=# CREATE TABLE tbl_c
> (id SERIAL PRIMARY KEY,
> da
On Mon, Apr 30, 2001 at 01:11:21AM -0400, Tom Lane wrote:
> Always remember that the cost estimates quoted by EXPLAIN are estimates,
> not reality.
>
> In this case the reason for the difference is that the planner doesn't
> have any detailed understanding of the semantics of bracket-expressions
On Sun, Apr 29, 2001 at 03:04:18PM +1000, Jeff Waugh wrote:
>
>
> > will trillich <[EMAIL PROTECTED]> wrote:
> >
> > >Care to explain -- in terms a Debian newbie might grok -- what
> > >"contrib/pgcrypto" means?
> >
> > Peter
On Thu, Apr 26, 2001 at 05:20:53PM +0200, Peter Eisentraut wrote:
> will trillich writes:
>
> > i know "password" can be used in creating/altering user
> > information (as used via GRANT and REVOKE) but is there any
> > facility within postgres to CRYPT() a va
On Wed, Apr 25, 2001 at 09:32:07AM +0200, Berényi Gábor wrote:
> I have been inserting records into a table using the SQL insert statement.
> One of the field types is serial, and I have been
> trying to figure out how to get the value that was assigned in the field as
> a result of the insert. Th
i know "password" can be used in creating/altering user
information (as used via GRANT and REVOKE) but is there any
facility within postgres to CRYPT() a value?
create rule new_folk as on insert to view_folk do instead
insert into folk_table
(create
On Tue, Apr 24, 2001 at 12:07:41AM -0400, Joel Burton wrote:
> On Mon, 23 Apr 2001, Paul Tomblin wrote:
>
> > Is the "BETWEEN" clause inclusive or exclusive? ie if I say "WHERE
> > latitude BETWEEN 45 and 55", will I get examples where the latitude equals
> > 45 or not? Also, is "latitude BETWE
On Mon, Apr 23, 2001 at 09:41:51PM -0400, Randall Perry wrote:
> on 4/23/01 9:20 PM, Randall Perry at [EMAIL PROTECTED] wrote:
>
> > This works:
> > $res = $conn->exec("select cust, contact, user_name, email from $t where
> > user_name = a1a");
> >
> > This doesn't:
> > $c = "a1a";
> > $res =
On Wed, Apr 18, 2001 at 09:01:21PM +0300, P. A. Bagyenda wrote:
> I am in the middle of a rather nasty experience that I hope
> someone out there can help solve.
>
> My hard disk partition with the postgres data directory got
> full. I tried to shut down postgres so I could clear some
> space
On Mon, Apr 16, 2001 at 03:43:23PM +0200, DaVinci wrote:
> Hello.
>
> When I create next function:
>
> create function pilpot() returns integer as '
> declare
> foo integer;
> begin
> foo = insert into aviso(user) va
On Mon, Apr 16, 2001 at 04:39:50PM +0200, Peter Eisentraut wrote:
> Patrick Dunford writes:
>
> > Zeos Database Explorer shows the type of these fields to be "bpchar", is
> > this a Postgres data type?
>
> bpchar is the internal name for char().
short for "blank-padded character". as opposed to
On Fri, Apr 13, 2001 at 02:28:29PM +0530, Masood Rezvi wrote:
> We are a firm of web developers in Lucknow, India. We are new
> to PGSQL but have this database on the webserver (Apache
> running on Linux Red Hat). We need help on learning PGSQL
> information on tutorials and also to know whether i
On Wed, Apr 11, 2001 at 10:25:24AM +0200, Marcin Wasilewski wrote:
> hello everybody,
> Can you help me?
>
> I have POSTGRESQL 7.0.3,
> I try to create simple view by typing.
>
> create view "xx" as select "aa.yy", "bb.yy" from "yy" order by "bb.yy"
>
> the problem is that parameter order is no
On Mon, Apr 02, 2001 at 02:02:51PM -0500, will trillich wrote:
> On Mon, Apr 02, 2001 at 10:21:34AM -0400, Tom Lane wrote:
> > Inheritance seems to work for this in current sources:
> >
> > regression=# create table p1 (f1 int);
> > CREATE
> > regression=# crea
On Tue, Apr 10, 2001 at 01:42:13PM -0400, Stan Brown wrote:
> I have been suing PostgreSQL quite happily in projects for
> several years now.
i have the smae porbelm -- you might wnat to solw down wehn you
tyep your email msesaegs.
Suing is quite different from Using.
:)
--
americans should n
On Tue, Apr 03, 2001 at 05:41:54PM +0300, Kris Van Hulle wrote:
> On 3 Apr 2001, at 10:31, Tom Lane wrote:
>
> > "Kris Van Hulle" <[EMAIL PROTECTED]> writes:
> > > Does PostgreSQL have support for virtual domains ?
> >
> > In 7.1 you can configure the postmaster to bind only to one specific IP
>
On Fri, Apr 06, 2001 at 01:26:39PM +0200, DaVinci wrote:
> On Fri, Apr 06, 2001 at 12:24:09PM +0100, Michael Ansley wrote:
> > >> Data Base:
> > >>
> > >> create table foo (
> > >> cod serial primary key,
> > >> explication text,
> > >>
On Sun, Apr 08, 2001 at 05:44:28AM -0400, Joel Burton wrote:
> On Tue, 3 Apr 2001, Nick T wrote:
> > I see that we can add users and delete or drop users. As the database
> > administrator, I'd like to be able to view all of the users and all of the
> > information about them. Couldn't find out
On Mon, Apr 02, 2001 at 10:21:34AM -0400, Tom Lane wrote:
> will trillich <[EMAIL PROTECTED]> writes:
> > i've tried
> > create function gpa(OPAQUE)
> > and psql tells me it successfully
> > CREATED
> > something, but
> >
On Fri, Mar 30, 2001 at 06:34:45PM -0800, Eric G. Miller wrote:
> On Fri, Mar 30, 2001 at 06:40:13PM -0600, will trillich wrote:
> > even using PLPGSQL, is it possible to send VARYING relation
> > tuples to a procedure/function -- so long as the attributes
> > (fields) munge
On Fri, Mar 30, 2001 at 06:02:27PM -0800, Soma Interesting wrote:
> At 06:47 PM 3/30/2001 -0600, you wrote:
> > > I may be able to use array's if postgres will allow using variables to
> > > reference points in the array.
>
>
> OK, so how do I reference a specific element of an array in a record
On Sat, Mar 31, 2001 at 12:42:29AM -0500, Tom Lane wrote:
> Soma Interesting <[EMAIL PROTECTED]> writes:
> > In the following, is there something I can do so that postgres will
> > evaluate NEW.qty to NEW.name, treating qty as a variable and evaluating it
> > before evaluating the field referenc
On Fri, Mar 30, 2001 at 04:39:21PM -0800, Soma Interesting wrote:
> At 05:47 PM 3/30/2001 -0600, you wrote:
> >HOWEVER -- we do have arrays, don't forget... sometimes they can
> >be bent to do more than intended (but usually not!)
> >
> > create table mailing(
> > person_id
On Fri, Mar 30, 2001 at 12:27:39AM -0500, Gregory Wood wrote:
> > SELECT sum(grade) / count(grade) As GPA FROM grades;
> > (bad juju if 0)
>
> No kidding... that kid totally failed ALL his classes! And before someone
> points it out, yes I saw the DBZ.
dbz?
--
does a
On Thu, Mar 29, 2001 at 06:05:04PM -0800, Eric G. Miller wrote:
> On Thu, Mar 29, 2001 at 01:17:29PM -0600, will trillich wrote:
> > is this kind of thing possible---?
> >
> > select gpa(student) from student where id=7121;
> > select gpa(course)
On Fri, Mar 30, 2001 at 10:57:42AM -0800, Soma Interesting wrote:
> In the following, is there something I can do so that postgres will
> evaluate NEW.qty to NEW.name, treating qty as a variable and evaluating it
> before evaluating the field reference? At this time it errors on an INSERT
> wit
On Thu, Mar 29, 2001 at 08:25:30AM +, Phuong Ma wrote:
> I'm using PostgreSQL version 7.1, and I'm having trouble with the LIKE
> statement. How would I find the value "a\bc"? I tried using the
> backslash to escape it: LIKE 'a\\b%';
>
> If I specify: LIKE 'a\\bc', then it works, but if I w
On Wed, Mar 28, 2001 at 11:46:42PM -0800, Soma Interesting wrote:
>
> >blah blah blah
> >
> >...and that all meant what? The postgres manual is open to much
> >interpretation to anyone new trying to understand its contents. Combine
> >that with documentation that's still not written, or broken
On Tue, Mar 27, 2001 at 09:52:05AM -0500, Bruce Momjian wrote:
> > On Mon, 26 Mar 2001 15:07:37 + (UTC), Mark Hamby
> > <[EMAIL PROTECTED]> wrote:
> > >
> > >
> > >Here's a patch for a \cd (change dir) command in psql program.
> > >It's very small and only adds a few lines.
> > >Personally, I
On Tue, Mar 27, 2001 at 03:58:39PM +0200, Christian Marschalek wrote:
> > Pg DOES support it!
> Oh... My fault :o)
>
> > However, it doesn't really have anything
> > to do with data redundancy. Data redundancy means storing
> > the same DATA in more than one table meaning that if it
> > change
On Mon, Mar 26, 2001 at 05:18:01PM +0200, [EMAIL PROTECTED] wrote:
> On 26 Mar 2001, at 3:42, Gary Huntress wrote:
>
> > I am looking for PostgreSQL users to beta test the following free database
> > hosting service:
> >
> > http://superid.dyndns.org:8080/freesql/index.php
> >
> > I've done
On Mon, Mar 26, 2001 at 03:42:43AM +, Gary Huntress wrote:
> I am looking for PostgreSQL users to beta test the following free database
> hosting service:
>
> http://superid.dyndns.org:8080/freesql/index.php
>
> I've done a fair amount of testing myself, but I need a few more people to
>
On Fri, Mar 23, 2001 at 05:28:24PM -0500, Gregory Wood wrote:
> Well, the problem is that currval() is the value last inserted by *that*
> backend into the database. The reasoning for this is simple:
okay ... :)
> If Paul just inserted a record and wants to find out what sequence value was
> ins
On Fri, Mar 23, 2001 at 09:29:17AM -, Michael Ansley wrote:
> I think that the standard way to do this is to use a resource identifier,
> and then have a separate table with all strings. That's the way that most
> internationalisation is done in programs, and it's probably not bad for
> datab
On Fri, Mar 23, 2001 at 09:53:49AM -0500, Gregory Wood wrote:
> > I have a table and want to make a view updateable with rules. Table has a
> > sequence that creates default value to primary key when inserting.
> >
> > And now the question: Is it posible to return value of primary key from
> >
On Fri, Mar 23, 2001 at 07:53:39AM +, Richard Huxton wrote:
> will trillich wrote:
> > is there a way to write sql/plpgsql that'll take a varchar
> > argument (table and field names) and be able to turn it into the
> > appropriate query?
>
> You can use th
let's say you have the name of a table in a string.
'mytable'
you also have field names, such as
'lookupfield' 'valuefield'
which would be assembled like this
select valuefield from mytable where lookupfield = '?'
is there a way to write sql/plpgsql that'll take a var
so who's got a clever implementation of cross-linguistic texts?
create table something (
id serial,
yadayada int4,
whatever date,
mumble float8,
en varchar(50), -- english
es varchar(50), -- e
On Thu, Mar 22, 2001 at 07:14:49PM -0600, will trillich wrote:
> CREATE VIEW who AS
> SELECT * from _who;
>
> CREATE RULE
> who_insert
> AS ON
> INSERT TO who
> DO INSTEAD
>
On Tue, Mar 20, 2001 at 08:26:58AM -0800, Roderick A. Anderson wrote:
> On Mon, 19 Mar 2001, will trillich wrote:
> > i'm wondering if any devious minds out there are using it for
> > something clever and useful, instead of doing the
> > roll-your-own table cross-looku
On Thu, Mar 15, 2001 at 07:35:27AM -0500, Russell Hires wrote:
> Sure did help me! Thanks! Since Debian does a lot of that stuff for you it's
> hard to follow along the instructions because they assume a source compile
> and install. The Debian related docs should say "After you've done 'apt-get
>
On Sun, Mar 04, 2001 at 04:52:16AM -0500, Jan Wieck wrote:
> will trillich wrote:
> > [...]
> >
> > CREATE TRIGGER _rating_propagate
> >BEFORE INSERT ON _rating
> >FOR EACH ROW EXECUTE PROCEDURE _rating_propagate();
> >
> > ERROR: NEW used in n
On Sun, Mar 04, 2001 at 07:07:24AM -0500, Jan Wieck wrote:
> will trillich wrote:
> > so altho the docs elsewhere say NOT to rely on access to the
> > pseudo table NEW within a trigger function, this part does work
> > like it should. but when i add SELECT or UPDATE it compl
On Tue, Feb 27, 2001 at 05:11:07PM +0100, Hans Jeuken wrote:
>
> I am busy writing a table editor in Perl, using the module Pg.pm as
> interface to Postgresql. When opening a table in that editor I would like
> to find out how the tables in the database are defined.
>
> So far I have considere
Mario Weilguni wrote:
>
> Am Mittwoch, 28. Februar 2001 10:43 schrieb will trillich:
> > so i've got my data recovered (thanks to oliver) and now
> > i wanna back it up with a pg_dumpall...
> >
> > instead, i get 'failed sanity check, type with oid 77992
hi. i've got a scenario i'd like to run past the pg/sql
experts...
short version: how can i have a trigger after insert, take the
fresh data and propagate changes to other tables in the database?
long version:
i'm using postgresql 7.0.3 on debian/potato -- and in trying to
implement a feedback
On Wed, Feb 28, 2001 at 09:31:35AM +, Oliver Elphick wrote:
> will trillich wrote:
> >NOW if i can just get PERL to work with DBD::Pg again, i'd
> >be done! this is gonna be fun to track down now that my data
> >is back...
> >
> >Can't loa
so i've got my data recovered (thanks to oliver) and now
i wanna back it up with a pg_dumpall...
instead, i get 'failed sanity check, type with oid 779927 was no
found' in the oddest places...
% pg_dumpall
[snip!!]
CREATE FUNCTION "get_disid" (int4,varchar ) RETURNS int4 AS '
SELECT
On Wed, Feb 28, 2001 at 06:52:01AM +, Oliver Elphick wrote:
> A pity the dump file got clobbered.
indeed!
> I suspect the dump from 6.5 was
> in a form that 7.0 rejected - you had those two failed creates in the
> log.
the problem was apparently
DEFAULT TEXT 'CURRENT_DATE'
in the da
Oliver Elphick wrote:
> will trillich wrote:
> >-rw---1 postgres postgres4 Feb 27 12:24 PG_VERSION
> >-rw---1 postgres postgres0 Oct 13 21:05 active
> >-rw---1 postgres postgres 8192 Feb 27 04:00 cust
> >-rw---
Oliver Elphick wrote:
>
> will trillich wrote:
> >aha. i found /var/lib/postgresql/data/automatic_update.log
> >containing, among other things:
> >
> >[snip]
> >You are now connected to database template1 as user will.
> >CREATE DATABASE
>
On Wed, Feb 28, 2001 at 01:12:47PM +1100, Andrew Snow wrote:
> Plus it might be a good idea if people teamed up and co-authored a book! I
> personally would be interested in writing something about functions and
> PL/PGSQL and so on, as it seems to me there needs to be somewhere with more
> examp
when upgrading from version X to version Y of postgres, the
install appears to dump the data and schema, and then suck it
back in with the new binaries.
[i just tried going from 6.5.3 to 7.0.3potato but the plpgsql.so
module wasn't installed and data types were conflicting, so the
new schema is a
79 matches
Mail list logo