Equipment of equipment name IP results
Beijing belong center office ME60 () is a field 222.83.19.109 CR56LPUF400A, 210305498910 j7000268, 03054989; CR56LPUF100B0, 210305377710 h3000190, 03053777; G1000861 CR56LPUF100B0, 210305377710, 03053777 (this is a field)
Shanghai 80 () is a field 222.83.19.158 CR52EAGF0, 0386751073000124, the PIC. CR52EAGF, 0278671073000167, LPU; CR52EAGF0, 0386751068000350, the PIC. CR52EAGF, 0278671067000055, LPU; CR52SRUA0, 0391091073000356, MPU; CR52SRUA0, 0391091073000342, SFU
. . . .
Which results in this field is very long, I just capture some of the paste, now to the results of this field to break up, for the first time into:
CR56LPUF400A, 210305498910 j7000268, 03054989
CR56LPUF100B0, 210305377710 h3000190, 03053777
CR56LPUF100B0, 210305377710 g1000861, 03053777
The second split
CR56LPUF400A 210305498910 j7000268 03054989
CR56LPUF100B0 210305377710 h3000190 03053777
CR56LPUF100B0 210305377710 g1000861 03053777
Then split fields from a list of other tables, the following
Equipment apanage device name IP type single board coding veneer description
Beijing (who center office ME60) a field 222.83.19.109 CR56LPUF400A 210305498910 j7000268 03054989
Beijing belong center office ME60 222.83.19.109 CR56LPUF100B0 210305377710 h3000190 03053777
Beijing belong center office ME60 222.83.19.109 CR56LPUF100B0 210305377710 g1000861 03053777
Shanghai huawei NE80E (80) 222.83.19.158 CR52EAGF0 0386751073000124 PIC
Shanghai 80 innings huawei NE80E 222.83.19.158... . .
. . . . . .
Now need to use oracle stored procedures to implement, I beginner, don't know how to do it, the trouble which give advice, online, etc., thank you
CodePudding user response:
In fact is the semicolon split time, according to the comma split againBreak up can use connect by cooperate REGEXP_SUBSTR, very troublesome
Seems there are some other exotic curiosity-a solution looking
This kind of thing I suggest don't put in storage process, which is difficult to write and maintain
With an external script, difficulty is reduced a lot, maintenance is easy
CodePudding user response:
You can use the instr function + substr function to help you solve this problemCodePudding user response: