group by

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Piedro

    group by

    Hi I've allready found the solution:

    select distinct(substr ing(beginx,2,2) ) as beginx ,
    count(distinct( substring(begin x,2,3))) as records
    from tc201
    where
    lijn is null and isnumeric(subst ring(vak,1,1)) = 1
    or
    lijn = 'nieuw' and isnumeric(subst ring(vak,1,1)) = 1
    group by substring(begin x,2,2)

    but thnx anyway
    Peter
Working...