I'm running into a syntax error:
You have an error in your SQL syntax. Check the manual
that corresponds to your MySQL server version for the
right syntax to use near ') AND Prof.WorkExp IN () AND
Prof_Industries.
Now I printed out the query and that works as I dumped
it into a mysql client and i
Looks like your $expLevl value is empty. It's probably set, but has no
value in it. Check that.
-TG
> -Original Message-
> From: Stuart Felenstein [mailto:[EMAIL PROTECTED]
> Sent: Thursday, December 02, 2004 1:46 PM
> To: [EMAIL PROTECTED]
> Subject: [PHP-DB]
--- "Gryffyn, Trevor" <[EMAIL PROTECTED]>
wrote:
> Looks like your $expLevl value is empty. It's
> probably set, but has no
> value in it. Check that.
>
No sorry to say that isn't it. It seems that for
every field i submit in the search, it's the field
right after where the syntax error is re
Stuart Felenstein wrote:
No sorry to say that isn't it. It seems that for
every field i submit in the search, it's the field
right after where the syntax error is reported. So ,
maybe it's not truly a syntax error.
Print out the entire query before you run it. Syntax errors are usually
pretty obv
can you post the code that creates the sql statement
bastien
From: Stuart Felenstein <[EMAIL PROTECTED]>
To: "Gryffyn, Trevor" <[EMAIL PROTECTED]>, [EMAIL PROTECTED]
CC: Stuart Felenstein <[EMAIL PROTECTED]>
Subject: RE: [PHP-DB] 5 hours later - sql error.
Date: Th
--- John Holmes <[EMAIL PROTECTED]> wrote:
> Stuart Felenstein wrote:
> Print out the entire query before you run it. Syntax
> errors are usually
> pretty obvious. If not, post the actual query here.
I found one possible syntax error and fixed it though
it seemed to have no effect. I'm postin
--- Bastien Koert <[EMAIL PROTECTED]> wrote:
>
> can you post the code that creates the sql
> statement
>
> bastien
>
I'm posting the entire script. I hope it comes
through legible. If not I can do an attachment so the
format, line breaks will remain.
0 AND is_array($taxType)) {
$s_
One observation:
> print_r($query_rsCS);
> if(!empty($aWHERE));
^ Remove semi-colon ?
> $query_rsCS .= ' WHERE '.implode(' AND ',$aWHERE);
> print_r($aWHERE);
HTH
Graham
--
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.
--- Graham Cossey <[EMAIL PROTECTED]> wrote:
> One observation:
>
> > print_r($query_rsCS);
> > if(!empty($aWHERE));
> ^ Remove
> semi-colon ?
>
> > $query_rsCS .= ' WHERE '.implode(' AND ',$aWHERE);
> > print_r($aWHERE);
>
> HTH
>
> Graham
>
Didn't do it. :
Stuart Felenstein wrote:
if(isset($stateReloc2)) $aWHERE[] = "Prof.State1 IN
($stateReloc2)";
You need to check if $stateReloc2, etc are empty() instead of set.
If the variable is set, but empty, you're going to end up with a
query like "Prof.State1 IN ()" which will cause your error, which
we woul
--- John Holmes <[EMAIL PROTECTED]> wrote:
> Stuart Felenstein wrote:
> > if(isset($stateReloc2)) $aWHERE[] = "Prof.State1
> IN
> > ($stateReloc2)";
>
> You need to check if $stateReloc2, etc are empty()
> instead of set.
> If the variable is set, but empty, you're going to
> end up with a
> que
--- John Holmes <[EMAIL PROTECTED]> wrote:
> You need to check if $stateReloc2, etc are empty()
> instead of set.
> If the variable is set, but empty, you're going to
> end up with a
> query like "Prof.State1 IN ()" which will cause your
> error, which
> we would have seen if you'd just posted th
John! Your the man! It works!
if (!empty(var))
Excellent. I think this is a good lesson in isset. I
assumed they were the same. I guess reading the
manual more would help.
Thank you.
Stuart
> --- John Holmes <[EMAIL PROTECTED]> wrote:
>
> > You need to check if $stateReloc2, etc are empty()
13 matches
Mail list logo