PATINDEX
REPLICATE
REVERSE
Repeats a string n times.
REPLICATE(str, n)
Enter values below to update the example in real time.
product_name
rating
stars
reviews
SELECT product_name, REPLICATE('★', rating) AS stars FROM reviews;