|
|
|
| Как в таблицу My SQL записать сразу несколько данных?
Вот пример:
INSERT INTO trivia (trivia_id, question, answer, alternative1, alternative2) VALUES (0001, 'Earth\'s outer layer of surface soil or crust is called the?', 'lithosphere', 'Lithosphere', 'Crust');
INSERT INTO trivia (trivia_id, question, answer, alternative1, alternative2) VALUES (0002, 'This county has the lowest point in South America', 'Argentina', 'argentina', NULL);
INSERT INTO trivia (trivia_id, question, answer, alternative1, alternative2) VALUES (0003, 'What\'s the worlds widest river', 'Amazon', 'amazon', '');
INSERT INTO trivia (trivia_id, question, answer, alternative1, alternative2) VALUES (0004, 'Who recorded \'Cuts Like a Knife\' in 1983', 'Bryan Adams', 'bryan adams', 'Bryan adams');
|
Это вопросы, которые нужно вставить в таблицу My SQL. Их всего 100, мне нужно вставить все сразу. Помогите, please!!!! | |
|
|
|
|
|
|
|
для: Eric
(28.10.2006 в 18:04)
| | Используйте многострочный оператор INSERT
INSERT INTO trivia (trivia_id, question, answer, alternative1, alternative2) VALUES (0001, 'Earth\'s outer layer of surface soil or crust is called the?', 'lithosphere', 'Lithosphere', 'Crust'),
(0002, 'This county has the lowest point in South America', 'Argentina', 'argentina', NULL),
(0003, 'What\'s the worlds widest river', 'Amazon', 'amazon', ''),
(0004, 'Who recorded \'Cuts Like a Knife\' in 1983', 'Bryan Adams', 'bryan adams', 'Bryan adams');
|
| |
|
|
|
|
|
|
|
для: cheops
(28.10.2006 в 22:02)
| | Спасибо Вам большое, попробую:) | |
|
|
|
|