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;
When i use the latest code, I have this error:
error msg "Aggregation expressions required by group by clause but i don't know why because i use all fields in Load in the group by
The error looks reasonable as there is no Sum,Min, Max, count being used to group values using group by fields. What exactly you want to aggregate?
Pick(Match() is just a conditional statement, it will assign the correct value to STATUT based on Statut_sup value but 'group by' is used to aggregate(sum,avg, min, max, count) facts based on our business needs.
ok...so this is not a solution for my question
If you uploaded a sample (it can be scrambled) then I could tell you what's the problem...
It's really hard without sample data...