Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I would like to use Preceding Load with this code :
LOAD
* WHERE "date"= Today() ;
load
date,
car as car,
mat ,
Tax,
'ON' as STATUT,
count(Statut_sup) as nbr
resident table1
where Statut_sup='Actif'
group by
date_flotte,
Taux,
//[%Date ID],
car ,
mat;
Concatenate
load
Pla,
date,
car as car,
mat,
'OFF' as STATUT,
count(Statut_sup) as nbr
resident table1
where Statut_sup='Inactif'
group by date,
car,
mat,
Pla;
Concatenate
load
date,
car as car,
mat,
'Bloquée' as STATUT,
count(Statut_sup) as nbr
resident table1
where Statut_sup='Bloquée'
group by date,
car,
mat;
drop table table1;
STORE [FlotteFinal] into [$(vQvdPath)\QVD_final.qvd](qvd);
Concatenate
Load*
resident Fact ;
drop table Fact;
Zied,
Here is a small method. You can alter the group by clause and the field names as per your need.
For Each Status in 'Actif', 'Inactif', 'Bloquée'
Result:
Load date,
car as car,
mat,
count(Statut_sup) as nbr,
Pick(Wildmatch(Statut_sup,'Actif','Inactif','Bloquée'),'ON','OFF','Bloquée') as STATUT
Resident table1
Where Statut_sup = '$(Status)' And Date = Today()
Group by date, car, mat;
Next Status
DROP Table table1;
STORE [FlotteFinal] into [$(vQvdPath)\QVD_final.qvd](qvd);
Concatenate
Load *
resident Fact ;
drop table Fact;
May be Field name misplaced STATUT instead of Statut_sup
Pick(Wildmatch(STATUTStatut_sup,'Actif','Inactif','Bloquée'),'ON','OFF','Bloquée') as STATUT