13.07.2015 Views

Hibernate Query Language Hibernate Query Language and Native

Hibernate Query Language Hibernate Query Language and Native

Hibernate Query Language Hibernate Query Language and Native

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

Setting Timeouttry {// retrieve accounts, allow 30 seconds<strong>Query</strong> getAccounts =session.create<strong>Query</strong>("from Account").setTimeout(30);List accounts = getAccountsPage1.list();}catch (<strong>Hibernate</strong>Exception) {...}...Setting Fetch Size• Optimization hint leveraged by theJDBC driver– Not supported by all vendors, but if available,<strong>Hibernate</strong> will user this to optimize data retrieval• Used to indicate the number of recordsexpected to be obtained in a readaction– If paging, should set to page size

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!