CIW
1D0-441 · Question #78
1D0-441 Question #78: Real Exam Question with Answer & Explanation
Sign in or unlock 1D0-441 to reveal the answer and full explanation for question #78. The question stem and answer options stay visible for context.
Question
Consider the following code fragment: 1. PreparedStatement ps = conn.prepareStatement 2. (INSERT INTO Orders VALUES (?, ?, ?, ?, ?)); 3. 4. ps.setInt(1, 4000); 5. ps.setString(2, 01-01-05); 6. ps.setInt(3, 1010); 7. ps.setInt(4, 200); 8. ps.setDouble(5, 1050.00); 9. ps.addBatch(); 10. 11. ps.setInt(1, 4001); 12. ps.setInt(3, 2010); 13. ps.addBatch(); 14. 15. ps.setInt(1, 4002); 16. ps.setInt(3, 3010); 17. ps.addBatch(); 18. 19. ps.clearBatch(); 20. 21. Statement s = conn.createStatement(); 22. ResultSet rs = s.executeQuery(SELECT * FROM Orders + 23. WHERE Sales_Rep_no = 200); 24. while(rs.next()) 25. { 26. System.out.print(rs.getString(Order_No) + ); 27. } Assume that variable conn references a valid and open Connection object to a database containing the Orders Relation (shown in the exhibit). Which output is generated
Exhibit
Options
- A4000
- B4002
- C4000 4001 4002
- DNo output is generated.
Unlock 1D0-441 to see the answer
You've previewed enough free 1D0-441 questions. Unlock 1D0-441 for full answers, explanations, the timed quiz mode, progress tracking, and the master PDF. Question stem and options stay visible so you can still see what's on the exam.
