PHP MySQL Trouble With the Syntax -


need advice php mysql syntax. work hard that, still facing problem query , error :

you have error in sql syntax; check manual corresponds mysql server version right syntax use near '$bagianwhere = ""' @ line 1: $bagianwhere = "" 

you can see demo here

please help!

if "bagianwhere" empty, sql query becomes invalid orphan "where" @ end. can

$bagianwhere = "1 = 1";

at top counter that.

also rid of "$bagianwhere .= " , make "$bagianwhere = "

also error mentioning here sql fiddle, have put in php code in there. can run php on web server , show error get.


Comments

Popular posts from this blog

java - JavaFX 2 slider labelFormatter not being used -

Detect support for Shoutcast ICY MP3 without navigator.userAgent in Firefox? -

web - SVG not rendering properly in Firefox -