Multiple choice technology web technology

Study following steps and determine the correct order (1) Open a connection to MySql server (2) Execute the SQL query (3) Fetch the data from query (4) Select database (5) Close Connection

  1. 1, 4, 2, 3, 5

  2. 4, 1, 2, 3, 5

  3. 1, 5, 4, 2, 1

  4. 4, 1, 3, 2, 5

Reveal answer Fill a bubble to check yourself
A Correct answer
Explanation

The correct order is: 1) Connect to MySQL server, 2) Select the database, 3) Execute the SQL query, 4) Fetch the data, 5) Close connection. This sequence (1,4,2,3,5 in the question's numbering) matches option A. Option B tries to select database before connecting - impossible. Option C and D have incorrect sequences.