Unpack and Transform Unidata Values
Hi team
New to this community and hoping please for some assistance. I have tried to work this out myself to no avail.
We have an SQL database that is connected to a unidata database. One of the tables is PURCHASES. This table stores Purchase Order header details and also the line level detail. It packs up the line details with a concatenation so if you want to view the line detail you have to unpack the concatenated value from the table into a view. For instance, purchase order 31935 has 4 purchase order lines and the system packs up the data like this (note delimeter is ý) (column name is v8);
206-5234; Primary Standard Efficiency Engine Air Filterý206-5235; Secondary Standard Efficiency Engine Air Filterý299-8229; FILTER AS-FUELýPLACED ONLINE – 00C280438
The system also has a column v120 which represents part number.
With all of that context out of the way – here is what I am trying to acheive;
1. Using vales from v8: 206-5234; Primary Standard Efficiency Engine Air Filterý206-5235; Secondary Standard Efficiency Engine Air Filterý299-8229; FILTER AS-FUELýPLACED ONLINE – 00C280438
2. update v120 with this; 206-5234ý206-5235ý299-8229ýPLACED ONLINE – 00C280438
Essentially take the text from the left of each semicolon (;) and remove other text to leave clean part numbers seperated with the delimeter ý
I hope this makes some form of sense. Hoping that this presents a challenge that someone is willing to assit with. Any assistance would be greatly appreciated.
Cheers Chris
Hi team New to this community and hoping please for some assistance. I have tried to work this out myself to no avail. We have an SQL database that is connected to a unidata database. One of the tables is PURCHASES. This table stores Purchase Order header details and also the line level detail. It packs up the line details with a concatenation so if you want to view the line detail you have to unpack the concatenated value from the table into a view. For instance, purchase order 31935 has 4 purchase order lines and the system packs up the data like this (note delimeter is ý) (column name is v8); 206-5234; Primary Standard Efficiency Engine Air Filterý206-5235; Secondary Standard Efficiency Engine Air Filterý299-8229; FILTER AS-FUELýPLACED ONLINE – 00C280438 The system also has a column v120 which represents part number. With all of that context out of the way – here is what I am trying to acheive; 1. Using vales from v8: 206-5234; Primary Standard Efficiency Engine Air Filterý206-5235; Secondary Standard Efficiency Engine Air Filterý299-8229; FILTER AS-FUELýPLACED ONLINE – 00C2804382. update v120 with this; 206-5234ý206-5235ý299-8229ýPLACED ONLINE – 00C280438 Essentially take the text from the left of each semicolon (;) and remove other text to leave clean part numbers seperated with the delimeter ý I hope this makes some form of sense. Hoping that this presents a challenge that someone is willing to assit with. Any assistance would be greatly appreciated. Cheers Chris Read More