我有很多行,其中包含不同列的不同值,但我只有一列 - DATA,如何在行中找到特定列值,看起来像
14000000PA1420000000PMP1 14200003093090006185211010012 240614000000250614 BUDAPEST VODAFONE POSTPAID PAYM 2030001025010000002660000348HUFFORINT 2506144261230042061365 0000000050 000000266000034800000026600003480000002660000348DALLOS SZILÁRD 022220049111250507201406250 000000266000042612314176001 000490836HU739900000000125050140625 fcbmc22.176
例如我需要第三列,它意味着14200(10位置到15位置)
我知道SUSBSTR,但它在其他行中的位置不同,所以我不知道每个位置,
谢谢。答案 0 :(得分:0)
Third_column := substr(your_string, 11, 5)
答案 1 :(得分:0)
似乎是一个简单的子串问题......
Select substr('14000000PA1420000000PMP1 14200003093090006185211010012 240614000000250614 BUDAPEST VODAFONE POSTPAID PAYM 2030001025010000002660000348HUFFORINT 2506144261230042061365 0000000050 000000266000034800000026600003480000002660000348DALLOS SZILÁRD 022220049111250507201406250 000000266000042612314176001 000490836HU739900000000125050140625 fcbmc22.176',11,5) as Col3
FROM DUAL;
收率:
Col3
14200