Results 1 to 3 of 3
  1. #1
    Join Date
    Sep 2006

    Unanswered: Oracle to Foxpro Query


    i m using this query in Oracle

    select * from xyz where rowid in(select max(rowid) from xyz group by party)

    i want to use this query in Visual Foxpro. but ROWID is not working in VFP.

    please give me alternate to rowid to use in VFP

    Thanks in Advance
    Last edited by younker1983; 06-02-07 at 01:39.

  2. #2
    Join Date
    Jan 2004
    Croatia, Europe
    Provided Answers: 4
    ROWID is unique, right? Is there any column in the 'xyz' table which is unique? Primary key column, for example? If so, use it! If not, create one (I'd use a sequence to do that in Oracle - I don't know what to do in Visual Foxpro). Finally, when you have that unique column, rewrite this query as
    SELECT * FROM xyz
    WHERE unique_column IN (SELECT MAX(unique_column) FROM xyz
                            GROUP BY party);

  3. #3
    Join Date
    Sep 2006
    Good Idea Bro Thanks

Posting Permissions

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