Results 1 to 2 of 2
  1. #1
    Join Date
    Feb 2009

    Question Unanswered: Alternative to FETCH FIRTST n ROWS ONLY

    Hi... i have to select 50 distinct records from a sub query... AS400 doesn't allow FETCH FIRTST n ROWS ONLY in sub query.. so is there any approach by which i can fetch only 50 distinct records from the subquery?

  2. #2
    Join Date
    Jan 2007
    Jena, Germany
    Do you have the ROW_NUMBER OLAP function? Then you can use that.
    Knut Stolze
    IBM DB2 Analytics Accelerator
    IBM Germany Research & Development

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts