Quantcast
Channel: PHP Freaks: PHP Help
Viewing all articles
Browse latest Browse all 13200

Joining two tables with the same rows

$
0
0

Hi! Can someone help me here? I just got this code from other topics and use it for my system but i have a problem

 

$idList = join (',', array_map('intval', array_keys($_POST['answers'])));		
$sql = "SELECT QuestionId, answer
FROM tblquestion_mc WHERE QuestionId IN ($idList";

 

what i am trying to do is to join my table: tblquestion_default to that code above but i don't know how to. 

 

My tables contain this:

 

table name: tblquestion_mc

QuestionId | Answer

 

table name" tblquestion_default

QuestionId | Answer


Viewing all articles
Browse latest Browse all 13200

Trending Articles