Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi
I have 2 tables :
QV_RET_OVED_VW with the columns :
COMMERCIAL_NUM,
COMMERCIAL,
GROUPE_OVED
QV_RET_FAMILLES_VW with the columns :
COMMERCIAL,
FAMILLE_NUM
YEARMONTH
I want to create a table QV_RET_GROUPE_OVED with the columns :
GROUPE_OVED
COUNT(FAMILLE_NUM)
That represents the count of FAMILLE_NUM for each GROUP_OVED and by YEARMONTH
I have tried with the expression 'Resident' but it doesn't work
Thank you for your help
Regards
Just load the tables:
QV_RET_OVED_VW:
Load
COMMERCIAL_NUM,
COMMERCIAL,
GROUPE_OVED
From QV_RET_OVED_VW_source;
QV_RET_FAMILLES_VW
Load:
COMMERCIAL,
FAMILLE_NUM,
YEARMONTH
From ...QV_RET_FAMILLES_VW_source...;
Then in the UI create a new straight table with GROUPE_OVED as dimension and count(FAMILLE_NUM) as expression. That's all you need.
If you feel you need to do it all in the script you'll have to join the tables:
Table1:
Load
COMMERCIAL_NUM,
COMMERCIAL,
GROUPE_OVED
From QV_RET_OVED_VW_source;
join (Table1)
Load:
COMMERCIAL,
FAMILLE_NUM,
YEARMONTH
From ...QV_RET_FAMILLES_VW_source...;
Table2:
Load GROUPE_OVED, count(FAMILLE_NUM) as Count
resident Table1
group by GROUPE_OVED;
Just load the tables:
QV_RET_OVED_VW:
Load
COMMERCIAL_NUM,
COMMERCIAL,
GROUPE_OVED
From QV_RET_OVED_VW_source;
QV_RET_FAMILLES_VW
Load:
COMMERCIAL,
FAMILLE_NUM,
YEARMONTH
From ...QV_RET_FAMILLES_VW_source...;
Then in the UI create a new straight table with GROUPE_OVED as dimension and count(FAMILLE_NUM) as expression. That's all you need.
If you feel you need to do it all in the script you'll have to join the tables:
Table1:
Load
COMMERCIAL_NUM,
COMMERCIAL,
GROUPE_OVED
From QV_RET_OVED_VW_source;
join (Table1)
Load:
COMMERCIAL,
FAMILLE_NUM,
YEARMONTH
From ...QV_RET_FAMILLES_VW_source...;
Table2:
Load GROUPE_OVED, count(FAMILLE_NUM) as Count
resident Table1
group by GROUPE_OVED;
abc:
Left Join(QV_RET_OVED_VW)
Load * resident QV_RET_FAMILLIES_VW;
Master:
Load GROUPE_OVED,
Count(FAMILLE_NUM) as CountofFAMILLE
resident abc;
Hi
Thanks for your response
But I need a table with the data and not to create a chart
Regards
Hey Ankri,
One which i mentioned will make table name Master with that data
Sorry but I don't understand
That is not working
See first you load both the tables
Table1:
Load COMMERCIAL_NUM,
COMMERCIAL,
GROUP_OVED
From QV_RET_OVED_VW;
Table2:
Load COMMERCIAL,
FAMILLE_NUM,
YEAR MONTH
FROM QV_RET_FAMILLE_VW;
After this two table get loaded,
Left Join(Table1)
Load * resident Table2;
Drop table Table2;
Master:
Load Group_OVED,
Count(FAMILLE_NUM) as Count_OF_FAMILLE_NUM
resident Table1;
Drop table Table1;
So You will Have Master table fianl consisting of required data
Thank you very much
Can you please Mark it correct if it is correct
Hi G WASSENAAR
If I have 3 tables to link, How can I do ?