Which two are reasons why you might set the bind variables of a view object at run time programmatically
rather than using the declarative features of the framework? (Choose two.)
Correct Answer: B,D
Explanation/Reference:
B: Whenever the WHERE clause of your query includes values that might change from execution to
execution, you can use named bind variables. These are place holders in the SQL string whose value you
can easily change at runtime without altering the text of the SQL string itself. Since the query doesn't
change, the database can efficiently reuse the same parsed representation of the query across multiple
executions which leads to higher runtime performance of your application.
D: If you use a named bind variable in your SQL statement but have not defined it, you'll receive an error
like this:
(oracle.jbo.SQLStmtException) JBO-27122: SQL error during statement preparation.
## Detail 0 ##
(java.sql.SQLException) Missing IN or OUT parameter at index:: 1
References: https://docs.oracle.com/cd/B31017_01/web.1013/b25947/bcquerying009.htm