Introduction
Sometime we may need to select the column results that the string starts with Vowels. In this article, We will have a look, How to select the columns results starting with Vowels.
Example
As an example, we have a StudentDetails table, first lets select all the results from the table.
SELECT [StudentId] ,[FirstName] ,[LastName] ,[RegistrationNumber] ,[Degree] ,[CreatedDate] ,[CreatedBy] FROM [PracticalWorks].[Details].[StudentDetails]
The above query’s result is as shown below,

Now lets select student names starting with Vowels.
SELECT [StudentId] ,[FirstName] ,[LastName] ,[RegistrationNumber] ,[Degree] ,[CreatedDate] ,[CreatedBy] FROM [PracticalWorks].[Details].[StudentDetails] WHERE LEFT(FirstName,1) in ('A','E','I','O','U');
The where clause applies the required condition. The LEFT function is used to access the first letter in this case. We want the first letter to be in the provided list of values which are the vowels.

Conclusion
In this article we have discussed about selecting the columns results starting with Vowels. I hope you all found this article useful. Please share your feedback in the comment section.
Leave a Reply