Don't like ads? PRO users don't see any ads ;-)
Guest

Untitled

By: a guest on May 10th, 2012  |  syntax: None  |  size: 1.38 KB  |  hits: 13  |  expires: Never
download  |  raw  |  embed  |  report abuse  |  print
Text below is selected. Please press Ctrl+C to copy to your clipboard. (⌘+C on Mac)
  1. Query from Hibernate App does not use DB indexes
  2. select *
  3. from (
  4.     select this.a, this.b, this.state, this.id
  5.     from view_user this
  6.     where this.state=:1 order by this.a asc, this.b
  7. )
  8. where rownum <= :2
  9.        
  10. Select * from (
  11.     select this.USER_ID as USER_ID0_, this.CLIENT_ID as CLIENT_ID0_,
  12.     this.USER_NAME as USER_NAME0_, this.USER_FIRST_NAME as USER_FIR5_0_, this.USER_REMARKS as
  13.     USER_REM6_0_, this.USER_LOGIN_ID as USER_LOG7_0_, this.USER_TITLE as USER_TITLE0_,
  14.     this.user_language_code as user_lan9_0_, this.USER_SEX as USER_SEX0_,
  15.     this.USER_BIRTH_DATE as USER_BI11_0_, this.USER_TELEPHONE as USER_TE12_0_,
  16.     this.USER_TELEFAX as USER_TE13_0_, this.USER_MOBILE as USER_MO14_0_,
  17.     this.USER_EMAIL as USER_EMAIL0_, this.USER_ADDRESSLINE1 as USER_AD16_0_,
  18.     this.USER_ADDRESSLINE2 as USER_AD17_0_, this.USER_POSTALCODE as USER_PO18_0_,
  19.     this.USER_CITY as USER_CITY0_, this.USER_COUNTRY_CD as USER_CO20_0_,
  20.     this.USER_COUNTRY_NAME as USER_CO21_0_, this.USER_STATE_ID as USER_ST24_0_,
  21.     this.USER_STATE as USER_STATE0_, this.USER_TEMP_COLL_ID as USER_TE26_0_,
  22.     this.USER_TEMP_COLL_NAME as USER_TE27_0_, this.UNIT_ID as UNIT_ID0_,
  23.     this.CLIENT_NAME as CLIENT_38_0_, this.PROFILE_EXTID as PROFILE39_0_
  24.     from VIEW_USER this
  25.     where this.USER_STATE_ID=:1 order by this.USER_NAME asc, this.USER_FIRST_NAME asc
  26. )
  27. where rownum <= :2
  28.        
  29. select *