Re: [PHP-DB] duplicated entry for key #

2001-12-18 Thread Russ Michell
'Duplicate entry 'username' for key 1. This means that you do have a duplicate entry in a row of your DB. Try setting a column as Auto increment: ALTER TABLE table_name id smallint(10) DEFAULT '0' NOT NULL auto_increment (or something like that) This means each set of data you put into the

[PHP-DB] Database query

2001-12-18 Thread Bzdpltd
Hi group, I am still getting to grips with PHP and MySQL and have a question that hopefully someone can easily answer: I have a search page which consists of two drop down menus, the user has 3 ways of finding information. The first is by selecting a location and a discipline which would

Re: [PHP-DB] Database query

2001-12-18 Thread Jon Farmer
Sorry the second elseif statement should have ended with : not ; -- Jon Farmer Systems Programmer, Entanet www.enta.net Tel 01952 428969 Mob 07763 620378 PGP Key available, send email with subject: Send PGP Key - Original Message - From: Jon Farmer [EMAIL PROTECTED] To: [EMAIL

[PHP-DB] Re: Database query

2001-12-18 Thread Fred
You are getting this result because you have all of those ORs in your statement. If any of them are true it will execute the query. If location finds a match ('$location' = location) it will execute the query regardless of whether discipline was empty or simply did not match. It is generally a

[PHP-DB] cannot connect to sybase, but no (undefined)errors

2001-12-18 Thread Peter Sands
Hi, I am tying to connect to sybase 11.9.2 from php 4.1.0 on aix. I have successfully installed php as a CGI (apache). The phpinfo() function tells me that sybase client is supported. But when I try to connect I get a failure $connection=sybase_connect(SYB_SRV, sa, pizza); ? if

RE: [PHP-DB] while...if statements???

2001-12-18 Thread Leotta, Natalie (NCI/IMS)
Have you tried printing out $pet_picture to make sure that it really equals when there's no pet? -Natalie -Original Message- From: Jay Fitzgerald [SMTP:[EMAIL PROTECTED]] Sent: Tuesday, December 18, 2001 3:09 PM To: [EMAIL PROTECTED]; [EMAIL PROTECTED]; [EMAIL PROTECTED]