Answer the question
In order to leave comments, you need to log in
How to get the value up to a specific character?
Good afternoon, please advise me on this issue. There is a part of the query
LEFT JOIN main_color c ON m.color = c.color_en
But the problem is that for example in the color column the value can be Yelow / White, and in the color_en table it will be exclusively Yellow, respectively, the query does not find such a value. Is it possible to somehow form a request so that everything in m.color would be cut off before / and then compared with c.color_en?
Answer the question
In order to leave comments, you need to log in
LEFT JOIN main_color c ON m.color LIKE '%'+c.color_en+'%'
what would cut everything in m.color up to / and then compare it with c.color_en?
LEFT JOIN main_color c ON m.color LIKE '%/'+c.color_en
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question