Exam Information
Free practice questions with explanations
Oracle 1Z0-909 Practice Questions
Answer a question to see the correct answer and the explanation, or click Show answer. Newest questions first.
- Questions
- 11
- Answered
- 0
- Correct
- 0
- Score
- -
-
1 Question 1 Single choice Connectors and APIs
A retail company is building a new order-entry service in Python that must connect to a MySQL 8.0 server. The security team requires that database passwords never appear in source code, configuration files checked into version control, or application logs, and that connections use TLS. The developers want a single mechanism that works across the team's laptops and the production containers. Which approach best meets these requirements?
Correct Answer: CExplanationThe mysql_config_editor utility stores connection parameters in an encrypted .mylogin.cnf file that client programs and supporting connectors can reference by login path, so no plaintext password appears in code or images. Pairing it with ssl-mode REQUIRED enforces encryption in transit. Storing credentials in a settings module keeps plaintext in version-controlled code, which breaks the policy. Passing the password on the command line exposes it in process listings. Embedding a password in the image and using PREFERRED allows unencrypted fallback, violating the TLS requirement.
-
2 Question 2 Order list Data-driven Applications
A developer must run a parameterised INSERT and SELECT from a Python application against MySQL 8.0 using server-side prepared statements, and must ensure any failure is reported with the server error code rather than a generic exception. Arrange the steps in the order they must be performed.
Drag the steps into the correct order, or use the arrows.
- Check the cursor warnings or fetch SHOW WARNINGS after execution
- Execute the prepared statement
- Prepare the SQL statement with ? placeholders on the connection
- Deallocate the prepared statement when it is no longer needed
- Bind the parameter values to the prepared statement
Correct Answer:- Prepare the SQL statement with ? placeholders on the connection
- Bind the parameter values to the prepared statement
- Execute the prepared statement
- Check the cursor warnings or fetch SHOW WARNINGS after execution
- Deallocate the prepared statement when it is no longer needed
ExplanationA server-side prepared statement must first be prepared so the server parses and stores the template, then values are bound to the placeholders, then it is executed. Warnings produced by the execution are retrieved afterwards, since SHOW WARNINGS reports diagnostics from the most recent statement. Deallocation comes last, once the statement is no longer required, freeing the server-side handle. Executing before binding would fail because the placeholders have no values.
-
3 Question 3 Single choice JSON and Document Store
A logistics company stores shipment events in a MySQL 8.0 table with a JSON column named payload. Analysts frequently filter on the value of the customer.region key, and the query on millions of rows performs a full table scan. The company cannot change the application's JSON structure and needs the fastest fix with minimal schema disruption. Which action is most appropriate?
Correct Answer: AExplanationMySQL 8.0 cannot index an arbitrary JSON path directly, so the standard technique is a virtual or stored generated column that extracts the scalar value, which can then be indexed. This keeps the JSON document unchanged and adds only a small schema change. Converting to TEXT loses JSON validation and does not support path lookups efficiently. A functional index on JSON_TYPE does not identify the region value. JSON_TABLE is a table function for shredding documents, not an optimizer hint.
-
4 Question 4 Drag and drop MySQL Schema Objects and Data
A telecom company designs a MySQL 8.0 schema that stores cell tower locations, phone numbers, call durations, and a daily report view that must stay consistent when the base table is updated. Match each requirement to the data type or object that best meets it.
Drag each item onto its matching target. On a phone: tap an item, then tap a target.
Store tower coordinates and compute distance within a radiusStore a phone number that may begin with a leading zero and is never used arithmeticallyPresent a daily summary that always reflects current base data and rejects updates that would break the summary ruleStore call duration in whole seconds with exact arithmetic for billing totalsPOINT with SRID 4326 and ST_Distance_SphereMEDIUMTEXT with a full-text indexENUM with a generated numeric codeVARCHARView created WITH CHECK OPTIONDECIMALCorrect Answer:- Store tower coordinates and compute distance within a radius → POINT with SRID 4326 and ST_Distance_Sphere
- Store a phone number that may begin with a leading zero and is never used arithmetically → VARCHAR
- Store call duration in whole seconds with exact arithmetic for billing totals → DECIMAL
- Present a daily summary that always reflects current base data and rejects updates that would break the summary rule → View created WITH CHECK OPTION
ExplanationSpatial coordinates belong in a POINT column with a spatial reference, and ST_Distance_Sphere computes great-circle distance for SRID 4326. Phone numbers need VARCHAR so leading zeros survive and no arithmetic is performed. Billing totals need exact decimal arithmetic, which DECIMAL provides rather than floating-point types. A view with WITH CHECK OPTION rejects modifications that would make rows invisible to the view, keeping its rule enforced. The distractors are plausible storage choices but fail the stated semantics.
-
5 Question 5 Multiple choice MySQL Stored Programs
A bank's batch team needs a stored procedure that transfers funds between two accounts and writes an audit row, and it must also run a nightly purge of audit rows older than 400 days without manual intervention. The DBA reviewing the design knows that DELIMITER is needed in the mysql client and that the default procedure characteristics affect replication safety. Which TWO statements about this design are correct? (Choose two.)
Correct Answer: A, EExplanationAn exit or continue handler for SQLEXCEPTION can roll back the open transaction and resignal, which preserves atomicity of the paired updates. Scheduling a recurring purge is done with CREATE EVENT and an ON SCHEDULE clause, and the event scheduler must be running. DETERMINISTIC concerns repeatable output, not modification, and is not a binary logging requirement. Triggers cannot schedule time-based work. SQL SECURITY INVOKER uses the caller's privileges, not the scheduler's, which is the opposite of what the event needs.
-
6 Question 6 Single choice Query Optimization
A reporting query joins orders (about 40 million rows) to customers and filters with WHERE customers.country = 'DE' AND orders.created_at >= '2023-01-01' ORDER BY orders.created_at DESC LIMIT 50. EXPLAIN ANALYZE shows a filesort over a large temporary set. The team can add one index and must not change the query text. Which index is most likely to remove the filesort while keeping the plan efficient?
Correct Answer: DExplanationBecause the join uses customer_id and the sort is on created_at, an index on orders(customer_id, created_at) lets the optimizer probe orders by customer and read rows in created_at order within each group, reducing the sort work. An index on created_at alone helps ordering but not the join probe, and the country filter lives on customers, so indexing only that table does not help the orders side. A customers-only index does not address the sort at all. The composite on orders with customer_id first is the pattern that removes the filesort under the stated constraints.
-
7 Question 7 Dropdown Transactions
A ticketing application must prevent two sessions from selling the same seat. Each booking session reads a seat row, checks availability, and updates it inside one transaction. The team wants a pessimistic lock that holds until commit and does not block readers of unrelated seats. Complete the statement that the booking code runs to lock the seat row.
Choose the correct value for each blank.
START TRANSACTION; SELECT status FROM seats WHERE seat_id = 42 ;Correct Answer:START TRANSACTION; SELECT status FROM seats WHERE seat_id = 42 FOR UPDATE;
ExplanationSELECT ... FOR UPDATE takes an exclusive record lock on the matched index row, so a concurrent booking for the same seat waits until the first transaction commits or rolls back, while other seats remain unaffected. LOCK IN SHARE MODE takes a shared lock, which still allows two sessions to read the status and then both update, defeating the goal. WITH ROLLUP is an aggregation modifier and has no locking role. NOWAIT SHARED is not valid MySQL 8.0 syntax for locking reads.
-
8 Question 8 Single choice Connectors and APIs
A Node.js service using the MySQL 8.0 server must retrieve rows and correctly handle DATE, DECIMAL, and NULL values without losing precision. The developer is considering using the default driver setting that converts DECIMAL to JavaScript Number. The financial reconciliation job cannot tolerate rounding error on amounts up to 18 digits. Which approach is the best choice for the driver configuration?
Correct Answer: BExplanationThe Node.js mysql driver converts DECIMAL to Number by default, which cannot represent all 18-digit values exactly. Enabling supportBigNumbers with bigNumberStrings returns DECIMAL as strings, and those can be handed to an arbitrary-precision library. Casting to DOUBLE introduces binary floating-point error, the exact problem to avoid. Disabling typeCast does not change the server's result types and produces no JSON. Rounding after conversion has already lost the digits, so it cannot restore precision.
-
9 Question 9 Single choice Data-driven Applications
A data engineer runs a bulk import into a MySQL 8.0 table with a column defined as VARCHAR(10) NOT NULL, and the script inserts values longer than ten characters. The table uses the default sql_mode, and the import reports success with warnings instead of failing. The compliance team requires that any truncation must stop the load immediately with an error. The engineer must change the behaviour at the session level only, without altering the server or other applications. Which action meets the requirement?
Correct Answer: BExplanationStrict mode for data modification is controlled by the sql_mode variable, and STRICT_ALL_TABLES makes truncation and other invalid data raise errors instead of warnings for transactional and non-transactional tables. Setting it at session scope affects only this import. SET GLOBAL alters every client and violates the scope constraint. IGNORE converts errors into warnings, the opposite of what is wanted. ALLOW_INVALID_DATES relaxes date checks and does nothing for string truncation.
-
10 Question 10 Order list Transactions
An order service must move a stock quantity from a warehouse row to a shipment row and insert an audit record, atomically, using InnoDB and the default REPEATABLE READ isolation level. A deadlock is possible if two transactions lock the rows in different orders. Arrange the steps in the order they must be performed to avoid that deadlock and keep the work atomic.
Drag the steps into the correct order, or use the arrows.
- Insert the audit row within the same transaction
- COMMIT the transaction, or ROLLBACK if any statement fails
- Start the transaction with START TRANSACTION
- Lock the warehouse and shipment rows in ascending primary key order using SELECT FOR UPDATE
- Apply the stock decrement and the shipment update
Correct Answer:- Start the transaction with START TRANSACTION
- Lock the warehouse and shipment rows in ascending primary key order using SELECT FOR UPDATE
- Apply the stock decrement and the shipment update
- Insert the audit row within the same transaction
- COMMIT the transaction, or ROLLBACK if any statement fails
ExplanationThe transaction must open first so every statement belongs to one unit of work. Locking the rows in a consistent ascending key order prevents two sessions from acquiring locks in opposite orders, which is the classic deadlock cause. The updates and the audit insert then run under those locks. COMMIT or ROLLBACK ends the transaction, releasing the locks, and must follow all the work. Locking after updating would let the update itself create the inconsistent acquisition order.
-
11 Question 11 Single choice JSON and Document Store
A team uses MySQL Shell to manage a document store named catalog in MySQL 8.0 and must give a reporting account read-only access to the collection products without granting it the ability to create or modify indexes or schema. Developers need the reporting account to run find() operations through the X Protocol. Which privilege grant is the most appropriate?
Correct Answer: DExplanationA collection in a MySQL 8.0 document store is stored as a table, and find() operations are executed through the X Protocol as SELECT statements against that table, so SELECT on the specific table grants exactly the required access without DDL rights. The reporter does not need ALL PRIVILEGES or a server-wide grant, which would violate least privilege. Granting CREATE allows schema changes the constraint forbids. The X Protocol is enabled on the server itself, not through a per-database setting.
These are 11 of the 65 questions in the full 1Z0-909 pack.
Get All 65 QuestionsGet all 65 questions & answers
Full access options for Oracle 1Z0-909
Self-study
PDF Version
- 65 actual exam questions
- Compatible with all devices
- Printable PDF format
- No download limits
- 90 days free updates
- 24/7 customer support
Best value
Bundle Pack
- Discounted PDF + online access
- 65 actual exam questions
- Both PDF and online practice test
- Free 90 days updates
- No download or practice limits
- 24/7 customer support
Exam simulation
Online Practice Test
- 65 actual exam questions
- Actual exam environment
- 90 days free updates
- Browser-based software
- 24/7 customer support
100% Money Back Guarantee
Your success comes first
At DumpsProvider, we give you a 100% money back guarantee on all of our exam dumps. For us, your success is the #1 priority and we are more than confident that our exam material will help you pass the 1Z0-909 Exam (MySQL 8.0 Database Developer) on your very first attempt.
In a rare case, if you fail your exam, we will refund your amount without asking a single question.