KEMBAR78
Coupon Code SQL | PDF
0% found this document useful (0 votes)
18 views1 page

Coupon Code SQL

The document outlines a grading setup with a maximum grade of 100 and restrictions on external content uploads. It specifies a query to extract unique customer names and generated coupon codes for cake orders, where the coupon code is formed by combining the first three characters of the customer name with the first three digits of their phone number. The results should be sorted by customer name in ascending order.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
18 views1 page

Coupon Code SQL

The document outlines a grading setup with a maximum grade of 100 and restrictions on external content uploads. It specifies a query to extract unique customer names and generated coupon codes for cake orders, where the coupon code is formed by combining the first three characters of the customer name with the first three digits of their phone number. The results should be sorted by customer name in ascending order.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 1

Coupon Code

Grade settings: Maximum grade: 100


Disable external file upload, paste and drop external content: Yes
Based on: Coupon Code
Run: Yes Evaluate: Yes
Automatic grade: Yes
Write a query to display the unique customer name and coupon code for the
customers who ordered cakes. The coupon code is generated by concatenating the
first three characters of the customer name, followed by the first three digits of the
phone number and give an alias name as 'Coupon_Code'.
Sort the results based on the customer name in ascending order.

You might also like