php-db | 2000121
Date: 12/09/00
- Next message: John Starkey: "Re: [PHP-DB] Checking before INSERT"
- Previous message: John Starkey: "[PHP-DB] Checking before INSERT"
- In reply to: John Starkey: "[PHP-DB] Checking before INSERT"
- Next in thread: John Starkey: "Re: [PHP-DB] Checking before INSERT"
- Reply: John Starkey: "Re: [PHP-DB] Checking before INSERT"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Sorry Charlie,
This aint dbase anymore.
If you really need to know if a row exists, you're gonna have to query the
database. You should be able to do a simple
SELECT count(*) cnt FROM your_table WHERE your_condition=true;
Client server architechure requires a little of work, but it's a lot more
powerful than good 'ol dbase.
"John Starkey" <jstarkey <email protected>> wrote in message
news:Pine.LNX.4.21.0012082335590.11437-100000 <email protected>
> Can someone tell me how to check that a row doesn't exist before I add
> it?
>
> Do I really have to create a conditional using $query, pg_Exec, and
> pg_result as the conditions?
>
> I've looked thru the PHP manual and the postgres sites and came up with
> nothing.
>
> Thanks,
>
> John
>
>
>
> --
> PHP Database Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: php-db-unsubscribe <email protected>
> For additional commands, e-mail: php-db-help <email protected>
> To contact the list administrators, e-mail: php-list-admin <email protected>
>
-- PHP Database Mailing List (http://www.php.net/) To unsubscribe, e-mail: php-db-unsubscribe <email protected> For additional commands, e-mail: php-db-help <email protected> To contact the list administrators, e-mail: php-list-admin <email protected>
- Next message: John Starkey: "Re: [PHP-DB] Checking before INSERT"
- Previous message: John Starkey: "[PHP-DB] Checking before INSERT"
- In reply to: John Starkey: "[PHP-DB] Checking before INSERT"
- Next in thread: John Starkey: "Re: [PHP-DB] Checking before INSERT"
- Reply: John Starkey: "Re: [PHP-DB] Checking before INSERT"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]

