Xavi Gracia wrote:
> 
> Hi !!!
> 
> I was wondering if there's any other method in SQL to test if a given record exists 
>that the typical error handling or the archetypical select clause looking for the 
>primary key.
> 
> I'm making a table where the e-mail adress is the primary key, nothing amazing but 
>it's my first MYSQL database. :-)
> 
> Another question, it's usual that if i try to add a new record with a e-mail address 
>already in, the php script didn't told me nothing about ( doesn't add the record, but 
>it didn't say nothing about duplicated record ).

You need to check the returned value from your insert statement, and
take appropriate action.

You should check the return codes of all sql statements.

---------------------------------------------------------------------
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/           (the list archive)

To request this thread, e-mail <[EMAIL PROTECTED]>
To unsubscribe, e-mail <[EMAIL PROTECTED]>
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php

Reply via email to