Examers.io
ExamsOrganizationsHow it worksPricingHelp & FAQ
GIAC (SANS) logo

GIAC Python Coder

Domain 2Objective 3

Database Interaction GPYC Practice Questions (Page 5)

Part of the Scripting and Automation domain, which makes up ~23% of our current practice bank. GIAC (SANS) does not publish an official question count, but from its 120-minute exam (~50–80 total, ~12–18 in this domain), expect 4–6 from this objective — we provide 30 practice questions to prepare you well beyond it. (estimate)

30questions here
6free pages
7concepts

Questions 21–25

  1. 21application · medium

    A Python script needs to connect to a SQL Server database using pyodbc. The script must ensure that the connection is closed even if an error occurs during query execution. Which pattern should be used?

    Select an answer first
  2. 22application · medium

    A Python application connects to a MongoDB database using pymongo. The application must handle connection failures and automatically reconnect when the database becomes available. Which approach is most appropriate?

    Select an answer first
  3. 23foundation · easy

    Which of the following is the primary security benefit of using parameterized queries instead of string formatting to build SQL statements?

    Select an answer first
  4. 24foundation · easy

    Which Python library is commonly used to connect to a MySQL database and provides a DB-API 2.0 compliant interface?

    Select an answer first
  5. 25foundation · easy

    What is the primary purpose of an Object-Relational Mapper (ORM) like SQLAlchemy?

    Select an answer first
Finished these 5 questions?

Review the revealed explanations, or continue through the curriculum.

Free Basic Practice is a study aid with revealable answers — not a scored exam. Examers.io is independent and not affiliated with or endorsed by GIAC (SANS). “GPYC” is a trademark of its owner, used for identification only.