aebstract Posted February 11, 2010 Share Posted February 11, 2010 I need to limit the results I am grabbing from my query, I need to check if the first 5 characters of the column are equal to 'TYSON'. I know how to do this if it's not "first 5 characters" of the column, anyone shed some light on this? Thanks Quote Link to comment Share on other sites More sharing options...
aebstract Posted February 11, 2010 Author Share Posted February 11, 2010 A more 'ghetto' way to do this, which I think will work in my situation, will be to grab all results where that column contains 'TYSON' regardless of position and regardless of first 5 characters. I think that would be easier to grab and I may be able to find a solution. Quote Link to comment Share on other sites More sharing options...
Mchl Posted February 11, 2010 Share Posted February 11, 2010 At least two ways to do this: WHERE columnName LIKE 'TYSON%' WHERE SUBSTR(columnName,1,5) = 'TYSON' Quote Link to comment Share on other sites More sharing options...
aebstract Posted February 11, 2010 Author Share Posted February 11, 2010 At least two ways to do this: WHERE columnName LIKE 'TYSON%' WHERE SUBSTR(columnName,1,5) = 'TYSON' Excellent, thanks a lot! Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.