|Welcome to the Monastery|
How do I extract named variable names from regex stringby maspsr (Initiate)
|on Jan 30, 2012 at 13:39 UTC||Need Help??|
maspsr has asked for the
wisdom of the Perl Monks concerning the following question:
I Have the following regex which I use when extracting information from different logfiles:
I would like to extract all the named parameters like ?<mon>,?<day>,.... to make sure that I haven't used same name twice. The string is composed from substring I have in a database. I have tried different approaches but until now without success. I thought I could use some repetitive pattern like
But I can't make it work. I could use the perl split function and probably get a list og the names.
any ideas ?