tool38 Posted November 20, 2009 Share Posted November 20, 2009 Hello Thanks for any help any one can give Im very new to PHP.. I need to pull data for clients that share 2 diff services into one table. mysql_select_db($database_pull, $pull); $query_Recordset1 = "SELECT * FROM RR_services WHERE USER_ID='XXXXX' and ( GAME_ID = 'RR6261678786234' or GAME_ID = 'RR4148833526812' )"; $Recordset1 = mysql_query($query_Recordset1, $pull) or die(mysql_error()); $row_Recordset1 = mysql_fetch_assoc($Recordset1); $totalRows_Recordset1 = mysql_num_rows($Recordset1); ?> This does what i need but i have to define the USER_ID i would like it to search all users and just display results of those that have both services.. Thanks Again, Quote Link to comment https://forums.phpfreaks.com/topic/182345-solved-filtering-tables/ Share on other sites More sharing options...
MatthewJ Posted November 21, 2009 Share Posted November 21, 2009 <?php mysql_select_db($database_pull, $pull); $query_Recordset1 = "SELECT * FROM RR_services WHERE GAME_ID = 'RR6261678786234' or GAME_ID = 'RR4148833526812'"; $Recordset1 = mysql_query($query_Recordset1, $pull) or die(mysql_error()); $row_Recordset1 = mysql_fetch_assoc($Recordset1); $totalRows_Recordset1 = mysql_num_rows($Recordset1); ?> Quote Link to comment https://forums.phpfreaks.com/topic/182345-solved-filtering-tables/#findComment-962284 Share on other sites More sharing options...
tool38 Posted November 21, 2009 Author Share Posted November 21, 2009 Thank you for the response . I started over and found a variable that both services shared so no need to filter.. Quote Link to comment https://forums.phpfreaks.com/topic/182345-solved-filtering-tables/#findComment-962402 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.