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

GIAC Python Coder

Domain 2Objective 3

Database Interaction GPYC Practice Questions (Page 2)

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 6–10

  1. 6application · medium

    A Python script processes a batch of INSERT statements into a PostgreSQL database. The script should commit the transaction only if all inserts succeed; otherwise, it should roll back. Which control flow correctly implements this?

    Select an answer first
  2. 7application · medium

    A Python script transfers funds between two bank accounts in a PostgreSQL database. It debits the source account, then credits the destination account. If the credit fails, the script must ensure the debit is not permanently saved. What is the correct approach?

    Select an answer first
  3. 8foundation · easy

    After executing a SELECT query, what does the cursor.fetchall() method return?

    Select an answer first
  4. 9foundation · easy

    What is the purpose of calling connection.rollback() in a database transaction?

    Select an answer first
  5. 10foundation · easy

    Which of the following is a benefit of using a database abstraction layer like SQLAlchemy Core?

    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.