Results 1 to 4 of 4
  1. #1
    Join Date
    Dec 2008
    Posts
    12

    Unanswered: Day function with Group By in Informix

    Hi,

    ı am trying to write an sql statement in informix, but it gives error.
    Does Informix not support using day function with Group By statement ?

    If not, is there a workaround ?

    Statement is:

    select day(call.startdatetime) , count(*) from call
    where month(call.callstartdate) = 11
    group by day(call.startdatetime);

    Thanks.

  2. #2
    Join Date
    Dec 2003
    Location
    North America
    Posts
    146
    You can use group by 1 in your "group by" statement with 1 representing the first column_name listed in your select statement.

    Same rule applies when using an "order by" statement.

  3. #3
    Join Date
    Dec 2008
    Posts
    12
    Thank you

  4. #4
    Join Date
    Dec 2003
    Location
    North America
    Posts
    146
    you're very welcome, glad to help

Posting Permissions

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