i have some multiple value fields (with values separated by ~~); otherwise the delimiter is the default pipe |
i want to create a new database by copying each record to the new database. i want to read each record and if it contains multiple values, i want to create a separate record in the new database for each record. each record in the new database should have only one value.
simplified example:
fields: ID name color city
record 1 :
1|john|red~~white~~blue|atlanta
i want the new database to contain the following 3 records:
1|john|red|atlanta
2|john|white|atlanta
3|john|blue|atlana
i can't figure out how to break apart the multi value and create a separate record for each value. can anyone help?
i want to create a new database by copying each record to the new database. i want to read each record and if it contains multiple values, i want to create a separate record in the new database for each record. each record in the new database should have only one value.
simplified example:
fields: ID name color city
record 1 :
1|john|red~~white~~blue|atlanta
i want the new database to contain the following 3 records:
1|john|red|atlanta
2|john|white|atlanta
3|john|blue|atlana
i can't figure out how to break apart the multi value and create a separate record for each value. can anyone help?