catpad (catpad) wrote,
catpad
catpad

Можете смеяться, но в догонку предыдущему посту я написал запрос для получения 100 самых средних файлов.



select * from [table_name] where rowid in
      (select rowid from
            (select rowid from [table_name] order by [file_size_column])
      where
       rownum >= NVL((select count(*) from [table_name]),0)/2-50
       and
       rownum <= NVL((select count(*) from [table_name]),0)/2+50
      );

Subscribe

  • Post a new comment

    Error

    default userpic

    Your reply will be screened

    Your IP address will be recorded 

    When you submit the form an invisible reCAPTCHA check will be performed.
    You must follow the Privacy Policy and Google Terms of use.
  • 3 comments