DesignO

Untitled

Oct 9th, 2014
181
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.33 KB | None | 0 0
  1. SELECT * FROM DIARIES
  2. WHERE
  3.  
  4. RECORD_DELETED = 0
  5.  
  6. AND WEB_ENABLED = 1 AND
  7.  
  8. PRACTICE_ID = 1 AND
  9. (
  10. (
  11. ((INACTIVE = :INACTIVE OR INACTIVE is null) AND ACTIVE_TO is null))
  12. OR
  13. (( INACTIVE = :INACTIVE OR INACTIVE is null)
  14. AND
  15. ACTIVE_FROM <= :ACTIVE_FROM AND
  16. ACTIVE_TO >= :ACTIVE_TO))
  17. ORDER BY DIARY_NAME ASC
Advertisement
Add Comment
Please, Sign In to add comment