column insert

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



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'");
    }
 Thanks for any help.
Phil Jourdan



[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