DV Query Plan differs between sql and prepared statement queries

Solution Verified - Updated -

Issue

  • Query plan is different for the same query in sql vs prepared Statement.

Environment

  • Red Hat JBoss Data Virtualization (DV) 6.4
  • Prepared Statement with criteria as parameters:
sql = "select * from " +
"Inventory_Detail" +
" WHERE SEARCH = and ITEM_ID in OFFSET 0 ROWS FETCH NEXT 500 ROWS ONLY";
PreparedStatement preparedStatement = conn.prepareStatement(sql);
preparedStatement.setString(1,"FALSE");
preparedStatement.setString(2,"1005014161091");
ResultSet rs = null;

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.

Current Customers and Partners

Log in for full access

Log In

New to Red Hat?

Learn more about Red Hat subscriptions

Using a Red Hat product through a public cloud?

How to access this content