Re: [PHP-DB] MySQL ERRORS

2007-05-07 Thread Chris

Chetan Graham wrote:

Hi to All,

I am having problems with the MySQL DB.  It started with this command from
a call in a PHP script...

"INSERT INTO docprouser (id,valid,password)VALUES
('user5','Y',md5('ksobhinyai'));" or die(mysql_error());"


That doesn't do anything (it will create a parse error).

You need to:

mysql_query("INSERT INTO docprouser (id,valid,password) VALUES( 
'user5','Y',md5('ksobhinyai'))") or die(mysql_error());


--
Postgresql & php tutorials
http://www.designmagick.com/

--
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP-DB] mysql errors....

2001-08-07 Thread Andreas D. Landmark

At 07.08.2001 20:39, Brian Weisenthal wrote:
>hey,
>
>im using php and mysql. i am sure that i am getting mysql errors but for
>some reason they are not being displayed making it real hard to debug. i
>hate debugging, im going to go insane..i cant see my errors
>helpplease, pretty please.thanks
>
>
>bwise


We can't see them from here either, so you better post some code to illustrate
your problem...



-- 
Andreas D Landmark / noXtension
Real Time, adj.:
 Here and now, as opposed to fake time, which only occurs there
and then.


-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-DB] mysql errors....

2001-08-07 Thread Brian Weisenthal

hey,

im using php and mysql. i am sure that i am getting mysql errors but for
some reason they are not being displayed making it real hard to debug. i
hate debugging, im going to go insane..i cant see my errors
helpplease, pretty please.thanks


bwise






-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




RE: [PHP-DB] mysql errors .... or php errors ????

2001-06-29 Thread Steve Brett

the code wasn't mine.

it was a drop in message board.

Steve

> -Original Message-
> From: Jason k Larson [mailto:[EMAIL PROTECTED]]
> Sent: 28 June 2001 11:12
> To: [EMAIL PROTECTED]
> Subject: Re: [PHP-DB] mysql errors  or php errors 
> 
> 
> Another thought came to mind.
> 
> These errors could be the result of verbose error reporting by PHP.
> php.ini or a script could be setting error reporting high 
> enough to display
> these errors, however it's extremely poor PHP coding syntax 
> to not correctly
> quote everything (except constants, of course).  One might 
> decide to resolve
> these errors once and for all by applying single or double 
> quotes on all
> named Array indexes.
> 
> For the short term you may look into error_reporting() in php.
> 
> Jason k Larson
> 
> 
> 
> -- 
> PHP Database Mailing List (http://www.php.net/)
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> To contact the list administrators, e-mail: 
> [EMAIL PROTECTED]
> 

-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP-DB] mysql errors .... or php errors ????

2001-06-29 Thread CC Zona

In article <[EMAIL PROTECTED]>,
 [EMAIL PROTECTED] (Steve Brett) wrote:

> 'invalid index test assumed 'test' in test.php at line 13'  can't
> remember the exact syntax but that's the general idea.
> 
> if i quote the var when i reference it the error goes away. like
> $arow['test'] as opposed to $arow[test].
> so in general i quote them always BUT i tried to set up a php members board
> on my server yesterday using someones elses code (blazeboard) and got
> hundreds of these errors whihc leads me to believe it's either my php or
> mysql setup ...

Strictly speaking, these are not supposed to be the same thing:

$myarray[index]  //key uses the value of a constant named "index"
$myarray['index'] //key is the literal string "index"

It's a PHP warning that you're getting.  Because it's an informational 
error rather than fatal, the parser continues on as long as it can find an 
element with that same name (even though it's looking first for the 
constant).  If there's any danger of there being confusion between a 
constant and array element with the same name, then you need to correct the 
quoting.  If you set your error_reporting level lower (you probably have it 
at E_ALL now) the warning will no longer appear; but understand that it'll 
still be *occuring*--it's just that you just won't be reminded of that fact 
anymore.  So you still need to watch what you name those constants and 
keys!  (And in the future, get in the habit of quoting keys correctly so 
there's no room for confusion.)

-- 
CC

-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP-DB] mysql errors .... or php errors ????

2001-06-28 Thread Jason k Larson

Another thought came to mind.

These errors could be the result of verbose error reporting by PHP.
php.ini or a script could be setting error reporting high enough to display
these errors, however it's extremely poor PHP coding syntax to not correctly
quote everything (except constants, of course).  One might decide to resolve
these errors once and for all by applying single or double quotes on all
named Array indexes.

For the short term you may look into error_reporting() in php.

Jason k Larson



-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




Re: [PHP-DB] mysql errors .... or php errors ????

2001-06-28 Thread Jason k Larson

This isn't a mySQL error.  PHP is complaining about the quoting of
variables.  Check for magic_quotes or the like in your php.ini file




-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-DB] mysql errors .... or php errors ????

2001-06-28 Thread Steve Brett

i know this may not be stricktly php but ...

soemtimes when i return queries from mysql to php i get errors like

'invalid index test assumed 'test' in test.php at line 13'  can't
remember the exact syntax but that's the general idea.

if i quote the var when i reference it the error goes away. like
$arow['test'] as opposed to $arow[test].
so in general i quote them always BUT i tried to set up a php members board
on my server yesterday using someones elses code (blazeboard) and got
hundreds of these errors whihc leads me to believe it's either my php or
mysql setup ...

any help would be greatly appreciated.

cheers,

Steve


-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]




[PHP-DB] MySQL errors on win32

2001-03-20 Thread Dirk Bonenkamp - Bean IT

Hi all,

I just installed apache, php & mysql on a win98 laptop. I normally use
linux 

Things work fine, but when I execute more queries in one script, I get
error messages like:

Warning: MySQL: Unable to save result set in c:/program files/apache
group/apache/htdocs/network-club.com/agenda.php4 on line 14

I saw something in the FAQ about this, but that was when upgrading.

I use Win98 SE UK, Apache 1.3.14, php 4.0.4pl1, Mysql 3.23.22-beta.

TIA,

Dirk


-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]