i am getting a input from user checking that value in db and if correct then doing some operation like
$getuser_key = $_POST['keyy'];
$sql = "SELECT * from demo_participant WHERE meeting_id_id IN(SELECT id FROM demo_meeting WHERE meetingID = '$get_meetingid') and `key` = '$get_meetinkey'";
mysql_real_escape_string($sql);
$result = mysql_query($sql) or die (mysql_error());
while ($row = mysql_fetch_array($result)) {
somthing
}
Can i use union operator ?
Now i want if the above query get failed then search $getuser_key
in another table
I just want to know that it is possible in this way or not if it is then how ?