Results 1 to 4 of 4
  1. #1
    Join Date
    Apr 2004
    Location
    Brussels
    Posts
    57

    Unanswered: odbc and 'order by'

    A select with 'group by' from MS-Access to linked table in informix generated error -309.
    The select is : "select a, b from tab1 group by a"
    When tracing the odbc (by odbc manager) it seems that Access first try to get the index : "select indx from tab1 group by a;" and this generate error -309 in Informix 7.31
    MS-Access 2003, XP, ODBC 3.82.0.2.81.TC1, IDS 7.31

    Have someone a solution for this problem ?
    Thanks a lot for help.
    Yves & Willy

  2. #2
    Join Date
    Mar 2004
    Location
    Netherlands
    Posts
    183
    Hi,

    I've nort checked the error message but normally in Informix you cannot select 2 columsn on which only one column is grouped. To bypass this limitation you have two solutions:
    select a, b from x group by a,b or
    select a, max(b) from x group by a

    In the second solution you need to use an aggregate function. Normally this should do the trick.

    Greetz,

    Rob

  3. #3
    Join Date
    Apr 2004
    Location
    Brussels
    Posts
    57
    Sorry, you are right,
    I mismake my question, my question must be about 'order by' and not 'group by' :

    The select statement is
    A select with 'ORDER BY' from MS-Access to a linked table in informix generates error -309.
    The select is : "select a, b from tab1 ORDER BY a"
    When tracing the odbc (by odbc manager) it seems that Access first try to get the index : "select indx from tab1 ORDER BY a;" and this generate error -309 in Informix 7.31
    MS-Access 2003, XP, ODBC 3.82.0.2.81.TC1, IDS 7.31

    Have someone a solution for this problem ?
    Thanks a lot for help.
    __________________
    Yves & Willy
    Yves & Willy

  4. #4
    Join Date
    Apr 2004
    Location
    Brussels
    Posts
    57
    solution :
    -migrate to ids9.40
    or
    - use old odbc driver
    or
    - call IBM support and convince them of these errors with trace

    I'm lazy and will use old odbc driver until migration
    Yves & Willy

Posting Permissions

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