19 Dec, 2024
1 min read

Write a Function that takes the customer number as input and returns the purchase_status based on the following criteria

If the total purchase amount for the customer is <25000 , status= Silver, If the total purchase amount for the customer is between 25000 and 50000, status= Gold, If the total purchase amount for the customer is >50000 , status= Platinum. The Payment table: Cust_number Check_No Payment_Date Amount 103 HQ336336 2004-10-19 6066.78 103 JM555205 2003-06-05 […]