For Programmers: Free Programming Magazines  


Home > Archive > PHP DB > September 2004 > Re: [PHP-DB] mysql to postgres migration blues...









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author Re: [PHP-DB] mysql to postgres migration blues...
Antoine

2004-09-23, 3:56 pm

On Thu, 23 Sep 2004 22:27:38 +0400, M Saleh EG <m.saleh.eg@gmail.com> wrote:
> define the connection object as a global var in ur function
>
> function ( params)
> {
> global $ur_connection_obj;
> ...
> ...
>

Damn you guys are quick! I like this list...
declaring it as global didn't seem to work -

global $link;
/* Connect to database */
$link = pg_connect("dbname=movies host=localhost user=anton
password=password")
or die("Could not connect : " . pg_result_error($link));

still didn't get it but passing it to the function did. I'll get
there, but I pretty much copied and pasted all the php up until now so
I have a little way to go...
Cheers
Antoine


--
G System, The Evolving GUniverse - http://www.g-system.at
Sponsored Links







Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive

Copyright 2008 codecomments.com