par
asma » 09 mars 2012, 16:40
svp qui peux m'aider j'ai un probléme avec la requette group by
select substr(wo.ORD_NR,1,3)"TAG",
wo.ORD_NR Orderno,
wo.ord_milestone Status,
cl.ORD_STEERINGTYPE Lenkerart,
wo.ORD_VEHICLETYPE Fahrzeugtyp,
wo.ord_orderlock"KSK Gesperrte",
wo.ORD_ARTICLELOCK "Module Gesperrte",
wo.ORD_TARGETTIME Produktionsminuten,
wo.ord_date1 "SET Termin",
wo.ord_lockreason "Sperrgrund",
wo.ORD_CHANGELEVEL "AS",
wo.ORD_REVI_NR Baugruppe,
wo.ORD_LINENR Lineno,
wo.ord_releasesequence Seqno,
count(*) Modulanzahl
from orders wo, articles,orders cl
where wo.ord_id = arti_ord_id
and wo.ord_productnr='01'
and cl.ord_id=wo.ord_ord_id
and (wo.ord_nr like &ORD_NR
or wo.ord_nr like &ORD_NR2)
group by substr(wo.ORD_NR,1,3),
wo.ord_date1,
wo.ord_milestone,
wo.ORD_NR,
wo.ORD_VEHICLETYPE,
cl.ORD_STEERINGTYPE,
wo.ORD_REVI_NR,
wo.ord_releasesequence,
wo.ORD_LINENR,
wo.ORD_TARGETTIME,
wo.ord_orderlock,
wo.ord_date1,
wo.ORD_ARTICLELOCK,
wo.ord_lockreason,
wo.ORD_CHANGELEVEL,
wo.ORD_NR having max(wo.ORD_CHANGELEVEL)>= 1
order by substr(wo.ORD_NR,1,3) ,
wo.ord_milestone,
wo.ORD_NR,
wo.ord_orderlock,
wo.ORD_ARTICLELOCK
svp qui peux m'aider j'ai un probléme avec la requette group by
select substr(wo.ORD_NR,1,3)"TAG",
wo.ORD_NR Orderno,
wo.ord_milestone Status,
cl.ORD_STEERINGTYPE Lenkerart,
wo.ORD_VEHICLETYPE Fahrzeugtyp,
wo.ord_orderlock"KSK Gesperrte",
wo.ORD_ARTICLELOCK "Module Gesperrte",
wo.ORD_TARGETTIME Produktionsminuten,
wo.ord_date1 "SET Termin",
wo.ord_lockreason "Sperrgrund",
wo.ORD_CHANGELEVEL "AS",
wo.ORD_REVI_NR Baugruppe,
wo.ORD_LINENR Lineno,
wo.ord_releasesequence Seqno,
count(*) Modulanzahl
from orders wo, articles,orders cl
where wo.ord_id = arti_ord_id
and wo.ord_productnr='01'
and cl.ord_id=wo.ord_ord_id
and (wo.ord_nr like &ORD_NR
or wo.ord_nr like &ORD_NR2)
group by substr(wo.ORD_NR,1,3),
wo.ord_date1,
wo.ord_milestone,
wo.ORD_NR,
wo.ORD_VEHICLETYPE,
cl.ORD_STEERINGTYPE,
wo.ORD_REVI_NR,
wo.ord_releasesequence,
wo.ORD_LINENR,
wo.ORD_TARGETTIME,
wo.ord_orderlock,
wo.ord_date1,
wo.ORD_ARTICLELOCK,
wo.ord_lockreason,
wo.ORD_CHANGELEVEL,
wo.ORD_NR having max(wo.ORD_CHANGELEVEL)>= 1
order by substr(wo.ORD_NR,1,3) ,
wo.ord_milestone,
wo.ORD_NR,
wo.ord_orderlock,
wo.ORD_ARTICLELOCK