Avatar of musickmann
musickmann
 asked on

Create multiple records in MySQL table based on value of one field.

I am looking to create multiple records based on a single value in a field in MySQL.

I have some data that looks like this in a table in MySQL

item_id | grade
12345 | 01
12346 | 05
12347 | 09-12

I need to transform it into something that looks like this:
12345 | 01
12346 | 05
12347 | 09
12347 | 10
12347 | 11
12347 | 12

Where 09-12 is can be a range of values
09-10
11-12
06-08
etc.
MySQL Server

Avatar of undefined
Last Comment
theGhost_k8

8/22/2022 - Mon
SOLUTION
Ares Kurklu

THIS SOLUTION ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
GET A PERSONALIZED SOLUTION
Ask your own question & get feedback from real experts
Find out why thousands trust the EE community with their toughest problems.
ASKER CERTIFIED SOLUTION
theGhost_k8

THIS SOLUTION ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
GET A PERSONALIZED SOLUTION
Ask your own question & get feedback from real experts
Find out why thousands trust the EE community with their toughest problems.
musickmann

ASKER
Thanks all, I'm still working on implanting these suggestions.
theGhost_k8

Author is requested to choose the best solution. Otherwise the points will be equally split between the two of the commenters offering solution.
This is the best money I have ever spent. I cannot not tell you how many times these folks have saved my bacon. I learn so much from the contributors.
rwheeler23