I am trying to get data from multiple tables and I got them while fetching data I am getting same data multiple time
How to stop echo data multiple times
<?php
$stmt = $DB_con->prepare('SELECT t1.id,t2.id from t1,t2ORDER BY t1.id DESC ');
$stmt->execute();
if($stmt->rowCount() > 0){
while($row=$stmt->fetch(PDO::FETCH_ASSOC)){
extract($row);
}
?>
This I am getting data but multiple times like t1 have 10 ids t2 have 20 ids so I got 30 IDs on the display