+ 1

SQL

I am new to SQL. I am writing a script to select all last names in database student that ends with upper case T And is at least 3 characters long in length. I know for upper case letter is SELECT * FROM Student WHERE StudentLastName LIKE ā€˜%Sā€™; But what about length? Please help!

29th Jun 2022, 3:09 PM
Knowledge Is Power
Knowledge Is Power - avatar
8 Answers
+ 4
Knowledge Is Power You can use len function len(name) >= 3
29th Jun 2022, 4:10 PM
AĶ¢J
AĶ¢J - avatar
+ 1
Knowledge Is Power In Feed Posts
29th Jun 2022, 5:05 PM
AĶ¢J
AĶ¢J - avatar
+ 1
Knowledge Is Power Do you see Posts in your profile?
29th Jun 2022, 5:44 PM
AĶ¢J
AĶ¢J - avatar
+ 1
Got it AĶ¢J I just posted there. Thank youšŸ‘
29th Jun 2022, 5:44 PM
Knowledge Is Power
Knowledge Is Power - avatar
+ 1
Hey. Use SELECT * FROM STUDENT WHERE STUDENTLASTNAME LIKE ā€˜%Tā€™ To get the data that ends with T
30th Jun 2022, 5:14 PM
Tomisin A.
Tomisin A. - avatar
0
AĶ¢J Do you how can i share ERD diagram at Sololearn?
29th Jun 2022, 4:33 PM
Knowledge Is Power
Knowledge Is Power - avatar
0
AĶ¢J where is feed post. I see Q&A and code playground. Where is feed post?
29th Jun 2022, 5:08 PM
Knowledge Is Power
Knowledge Is Power - avatar
0
The ? symbol can be used as a wildcard placeholder that represents 1 unknown character. Change the LIKE clause to look like this: StudentLastName LIKE '%??T'
4th Jul 2022, 7:17 PM
Brian
Brian - avatar