Using Oracle 11g, I have the following LDAP string which is only a subset of what I am trying to demonstrate here.
Basically I have a very long string that is causing me ‘string literal too long’ issues and basically within this string, I want to be able to either strip out the bits I don’t want or even better, strip out the only bits that I need.
This is only a short version of the string contents/length:
Member of = CN=aTIGERAdmin-Admin, CN=D0902498, CN=ea90045052, CN=aTIGERCall-Admin, CN=DAaTIGERCall-Admin, CN=DAaTIGERCall-Admin, CN=DAaTIGERCall-Admin, CN=DAaTIGERCall-Admin, CN=DAaTIGERCall-Admin, CN=DAaTIGERCall-Admin, CN=DAaTIGERCall-Admin, CN=DAaTIGERCall-Admin, CN=DAaTIGERCall-Admin, CN=aTIGERAdmin-Admin, CN=ea90045052, CN=DAaTIGERCall-Admin, CN=DAaTIGERCall-Admin, CN=DAaTIGERCall-Admin, CN=DAaTIGERCall-Admin, CN=DAaTIGERCall-Admin, CN=DAaTIGERCall-Admin, CN=DAaTIGERCall-Admin, CN=DAaTIGERCall-Admin, CN=aTIGERCall-Admin, CN=aTIGERAdmin-Admin, CN=D0902498, CN=ea90045052, CN=aTIGERCall-Admin, CN=DAaTIGERCall-Admin, CN=DAaTIGERCall-Admin, CN=DAaTIGERCall-Admin, CN=DAaTIGERCall-Admin, CN=DAaTIGERCall-Admin, CN=DAaTIGERCall-Admin, CN=DAaTIGERCall-Admin, CN=DAaTIGERCall-Admin, CN=DAaTIGERCall-Admin, CN=aTIGERAdmin-Admin, CN=ea90045052, CN=DAaTIGERCall-Admin, CN=DAaTIGERCall-Admin, CN=DAaTIGERCall-Admin, CN=DAaTIGERCall-Admin, CN=DAaTIGERCall-Admin, CN=DAaTIGERCall-Admin, CN=DAaTIGERCall-Admin, CN=DAaTIGERCall-Admin, CN=aTIGERCall-Admin,
Assume the above is greater than 4000 characters long.
My issue is, using Oracle SQL and PL/SQL and the above “member of” string, I need to somehow filter out only the bits that look like ‘CN=aTIGER%’ and completely ignore entries that look like ‘CN=DAaTIGER%’ which I believe, we solve my string literal issues but I am unable to filter this out first as my original string is already greater than 4000 chars long.
Using pl/sql, I am seeking an approach that will only return the entries inside “member of” that look like ‘CN=aTIGER%’ and completely ignore entries that look like ‘CN=DAaTIGER%’ at the same time, ensure that there is also a comma at the end of the result.
Do I need to assign this to a CLOB and then process the entries I need?
CN=D0902498orCN=ea90045052?