Generate exam save question select question number from the database, and then typeset to generate a Exam. The next step is to save the exam question? Do you have any good suggestions? Can I generate word for all the content of the exam and save it? Or are you sure you want to extract the question number when you want to extract this exam ?, Discuss the question of P_ID exam No. P_NAME exam name P_TIME generating exam storage
Select question numbers from the database, and then typeset to generate a test paper
What follows is the question of saving the exam?
Do you have any good suggestions?
Can I generate word for all the content of the exam and save it?
Or are you sure you want to extract the question number when you want to extract this exam?
------ Solution --------------------
Discussion
P_ID exam No.
P_NAME exam name
P_TIME
T_ID instructor ID
So how do you differentiate the created tables from different tests?
You are equivalent to my question bank ··
What I want is to extract some question numbers from the question bank to create a new exam table,
------ Solution --------------------
Yes. The varchar type is sufficient. In this case, select * from THE where id in ('1, 2, 3 '); // Obtain the questions 1, 2, and 3.
------ Solution --------------------
PHP code
Just put it together: 1: $ a = 1; $ B = 2; $ c = 3; $ code = $. ",". $ B. ",". $ c; 2: $ a = array (1, 2, 3); $ code = implode (",", $ ); $ SQL = "select * from table where code in (". $ code. ");"
------ Solution --------------------
Discussion
Question numbers are separated by commas. is that string type? How can we extract the data during extraction?
------ Solution --------------------
When saving, use the question number and store it in a good connection. Loop output is required for extraction.