CBSE Class 12 Computer Science Question 41 of 47

Interface Python with SQL — Question 4

Back to all questions
4
Question

Question 4

To disconnect database connection, use connect() method.

Answer

False

Reason — The correct method to disconnect from a database connection is connection.close() or cursorobject.close(). On the other hand, the connect() method is used to establish a connection to the database.