i have two tables named files, director. i want to select all data from director and select two columns from files this is code
$acc_no=$_POST['acc_no'];
$q="select * from files,director_recovery where account_no='$acc_no'";
i have two tables named files, director. i want to select all data from director and select two columns from files this is code
$acc_no=$_POST['acc_no'];
$q="select * from files,director_recovery where account_no='$acc_no'";
For selecting data from 2 tables you can use JOIN
SELECT director_recovery.*, files.col1, files.col2
FROM director_recovery
JOIN files on files.account_no = $acc_no
I think this may help you