1

I cant resolve this since this morning,

I have a dataset with 2 columns : id_campaign and id_client

enter image description here

I need to know the number of client in a couple of campaign, he an exemple :

I want a dataset like this :

enter image description here

But with this command I have 0's or I want the number of crossed campaign

Have you got any ideas please ? I can explain more if necessary

Edit : I can do it in PySpark or in Python

And I tried multiple combinations of aggregation with groupBy() ; pivot_table() ; and partitionBy() without satisfying results

Robin
  • 51
  • 5
  • I don't get your expected output, do you mind explaining it? – pltc Sep 23 '21 at 15:11
  • Thanks for your answer, I want the number of client contacted by 2 campaigns for every couple of campaign by example in the cells column "5211" row "5210" I want the number of client who has a line with the id camp '5211' AND '5210' (in the example the client "0000162100" should be counted for one – Robin Sep 24 '21 at 08:22
  • I see, please put your sample input and expected output in table format? that would help us a lots on troubleshooting and debugging – pltc Sep 24 '21 at 15:31

0 Answers0