Why this MySQL Query Not working? -
Why this MySQL Query Not working? -
i have wrote mysql query check rows between given start , finish time, doesn't work, please help me find error?
query:
select * users user_id='".$input['guard']."' , (start_time >= '".$startdatetime."' or finish_time <= ".$finishdatetime."'
error:
syntax error or access violation: 1064 have error in sql syntax; check manual corresponds mysql server version right syntax utilize near '' @ line 3 (sql: select * users user_id='13' , (start_time >= '2014-10-20 10:30:00' or finish_time <= '2014-10-20 21:30:00' )
$guard=$input['guard']; $sql="select *from users user_id='$guard' , (start_time >='$startdatetime' or finish_time <='$finishdatetime')";
mysql
Comments
Post a Comment