Error searching 2 fields

C

Carl Underwood

Guest
Error during query execution.
select * from hist0102 where lname = 'XXXXX' descrip like '%Kmart%'
MySQL server said: You have an error in your SQL syntax near 'descrip like '%Kmart%'' at line 1

It would seem that the script is not putting in an "and" between the first search filed and the second.

Not being very well versed in PHP, I'm at a loss as to how to fix.

Otherwise, the script is just what I've been looking for.

Thank you,

Carl Underwood
 
E

Eugenio

Guest
Carl Underwood wrote:
>
> Error during query execution.
> select * from hist0102 where lname = 'XXXXX' descrip like
> '%Kmart%'
> MySQL server said: You have an error in your SQL syntax near
> 'descrip like '%Kmart%'' at line 1
>
> It would seem that the script is not putting in an "and"
> between the first search filed and the second.

Could you give more details?
For example: When the error appears? During an search?

(Latest version of DaDaBIK when this message was posted: 1.8)
 
Top