*/
private Holding SQLSelectHolding(TextData pSelHoldCustName, String pSelHoldStockName) {
Holding aHolding = new Holding();
int recsReturned = 0;
int qq_RowCount = 0;
DBConnectionManager dBConnection = DBConnectionManager.getInstance("DBConnection");
// -- =============== Original SQL ===============
// select * into :aHolding from Holding
// where CustomerName = :pSelHoldCustName
// and StockName = :pSelHoldStockName
// on session DBConnection
// -- ============================================
String qq_SQL = "select * from Holding " +
"where CustomerName = ? " +
"and StockName = ? ";
Object[] qq_SQLParams = new Object[] {
pSelHoldCustName,
pSelHoldStockName
};
// TODO [112,Info]: Using the * in a query rather than explicitly enumerating the column list is often inefficient.
JdbcTemplate qq_Template = dBConnection.getTemplate();
List qq_List = qq_Template.query(qq_SQL, qq_SQLParams, new BeanRowMapper(aHolding, Holding.class));
if (!qq_List.isEmpty()) {
aHolding = (Holding)DataAccessUtils.singleResult(qq_List);
}
qq_RowCount = qq_List.size();