Hi again, Family.
I am rereading up on SPL (which I have not touched in nearly 30 years - and the times, they are a-changin'!) because I found a user request for an interesting constraint on a column in a table.
- It must look like an email address i.e. yodel@spaceballs.org. (or maybe yodel@spaceballs.org.en for a British email address.)
- It may contain several email addresses, separated by a semicolon.
- But a maximum of 3 email addresses.
I don't believe there is any MATCHES or LIKE expression in SQL that would work for such a complex requirement. I might conceive of a regular expression in Perl that might handle this but for a check constraint? Well, for a complex check like this I suppose we'd go to stored procedure invoked in the AFTER clause of the trigger. But is such detailed character manipulation even possible in SPL? My instincts leads me to an external procedure/function but written in Perl. But I'm mainly curious if it is possible in SPL.
Ideas, anyone?
------------------------------
Jacob Salomon
---
Nobody goes there anymore, it's too crowded. --Attr: Yogi Berra
------------------------------