受け取った仕様テーブルの値に応じて、テーブルのすべての「車」を「仕様」のリストに表示しようとしています。
テーブル:
車:
dcar: 1 / width:30 / length:10 / weight:300
idcar: 2 / width:20 / length:12 / weight:210
idcar: 3 / width:20 / length:21 / weight:230
idcar: 4 / width:40 / length:11 / weight:210
スペック表:
idspec:1 spec:width
idspec:2 spec:weight
idspec:3 spec:length
出力は次のようになります。
Width
car-1 width-30
car-2 width-20
car-3 width-20
car-4 width-40
Weight
car-1 weight-300
car-2 weight-210
car-3 weight-230
car-4 weight-210
Length
car-1 length-10
car-2 length-12
car-3 length-21
car-4 length-11
私の質問は大丈夫ですか?しばらくの間、または foreach (php) で使用したい
$resultjoin = mysqli_query($connecDB,"SELECT specs.idspec, specs.spec, cars.idcar FROM (specs) LEFT JOIN cars ON cars.idcar = specs.idspec");
ありがとうございました!