I think u did same type of question for min and Max orderdate using joins for two different cte
@tusharshrikhande32632 ай бұрын
Is dsa needed for data engineering roles?
@MeanLifeStudies2 ай бұрын
Yes, at least easy to medium-level. Since questions will be asked during interviews.
@prakxsh_2 ай бұрын
Can we do first find the min and max date by customer and make the subtraction.. from the subtraction results.. give the customer id which transaction amount greater than subtraction results
@MeanLifeStudies2 ай бұрын
We have to return transaction amount for both min and max dates. So we should use aggregate, grouping and having clauses. But doing this we can extract those values in rows. Again it's complex.
@prakxsh_2 ай бұрын
@@MeanLifeStudies got it sirr
@namangarg70232 ай бұрын
First u join min date values then Max date values and then final join between min and Max which u did in that video
@MeanLifeStudies2 ай бұрын
Yes, we can. Try to explain about first and last values in window functions. We should also concern query optimization. Joins are costly too right?
@pallethirumalreddyreddy50502 ай бұрын
Hi Sir for Transaction Id 101 and 119 was done by customer id 2 on same date so we have to add and then we have to calculate i think. Please rectify me if i am wrong.
@MeanLifeStudies2 ай бұрын
Yes. I observed that too while I was solving it. I guess anyone will ask this question. we should understand the question clearly. the first and last transaction amount difference. customer can do multiple transactions on the first and last day of transactions. But we should consider the first one on the first day and the last one on the last day. I hope you get it now.