I am trying to understand if there is a way we can use SPLIT_PART in Snowflake that will break down the users from a LDAP Membership. If not SPLIT_PART, any other approaches?
The following exists as a single record which I want to split as three records extracting only the CN.
CN=John Doe,OU=Enabled Users,OU=User Accounts,DC=COM;CN=Mark Stu,OU=Enabled Users,OU=User Accounts,DC=COM;CN=Rachel Gail,OU=Enabled Users,OU=User Accounts,DC=COM
I wanted to split them as
- John Doe
- Mark Stu
- Rachel Gail
I think split_to_table may be a little easier, but if yours works either should be fine:
This is assuming you have a table named TABLE_A with a column named MEMBER holding the LDAP strings.