Re: column insert

From: Scott Marlowe <scott(dot)marlowe(at)ihs(dot)com>
To: "P(dot) Jourdan" <pippo(at)videotron(dot)ca>
Cc: <pgsql-php(at)postgresql(dot)org>
Subject: Re: column insert
Date: 2002-05-02 21:31:35
Message-ID: Pine.LNX.4.33.0205021530580.5658-100000@css120.ihs.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-php

On Thu, 2 May 2002, P. Jourdan wrote:

> I have to insert 2 columns into an existing database that seems to be
> altered after a restore. I do not know what datatype should be entered for
> "path" and for "referer". The others are int4 and timestamptz for when_stamp.
> Here is the code:
> /*
> * Statistics: write page view
> */
> if($loglevel>=1) {
> sqlquery("
> insert into visits (session_id,page_id,when_stamp,path,referer)
> select session_id,$page_id,'now','$REQUEST_URI','$HTTP_REFERER'
> from session
> where hash='$sid'");
> }

You're probably best off using text type. Try this:

alter table visits add path text;
alter table visits add referer text;

That should get ya there.

In response to

Browse pgsql-php by date

  From Date Subject
Next Message Keary Suska 2002-05-02 21:33:41 Re: boolean error
Previous Message Surojit Niyogi 2002-05-02 21:20:42 Re: boolean error