Reputation:
I have a column called Data1 the column contains the following data "Apples|Farmer|11"
Data1
"Apples|Farmer|11"
How do I select "Farmer" from Data1 in a select
"Farmer"
select data1 from tblMyTable
Upvotes: 0
Views: 295
Reputation: 3251
SELECT SUBSTRING_INDEX('Apples|Farmer|11', '|', 2)
Upvotes: 5