Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

Databases SQL Reporting by Example Orientation: Selecting Data Orientation Quiz

DATABASES THIS IS THE CODE THAT NEEDED TO BE FILLED Return only students whose last name ends in 'x':

SELECT * FROM STUDENTS WHERE LAST_NAME ..........;

N I FILLED IT WITH "LIKE '%X%' " AND X% BUT STILL NO LUCK

Mark Miller
Mark Miller
45,831 Points

This has already been answered, but I'll add my comment anyway. The percent sign means "anything" in this SQL, so you can quote "anything x" to say anything could come first but x must be the last character. You've tried x before anything and anything before and after x. Make sure to quote "anything before x." This subject is called regular expressions or pattern matching if you want to dive in for more.

3 Answers

Hello there,

You're close - it's the one you haven't tried yet. To get names that end in 'x', you want

LIKE '%x'

The % is where the rest of the text goes, so if you're looking for things that end a certain way you want the % first.

thanks Katie

still bummer

One other problem I noticed is that the opening and closing quotes from an iPad are not being recognized, therefore consider using other gadgets or copying the quotes on another text