Link to home
Start Free TrialLog in
Avatar of liltyga
liltyga

asked on

Oracle Trigger to Force Lowercase

Hello,

I am trying to find out how to write a trigger asap that can force all of the data going into one of my tables to be entered as lowercase, along with the unique constraint, to make sure that all data is, in fact unique. Can anyone help?
ASKER CERTIFIED SOLUTION
Avatar of ToddBarry
ToddBarry

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of Mark Geerlings
You have two suggestions already on converting values to lower case.  Don't use a trigger though to enforce uniqueness - that is not the best way to do that.  Use a primary or unique constraint on the column(s) instead.
Avatar of liltyga
liltyga

ASKER

thanks everyone!  for markgeer - i do have a unique constraint and primary key in place, but the values are still case insensitive, so I wanted this to ensure all possibilities of dupe data are avoided.
I guess you didn't like my answer?
Avatar of liltyga

ASKER

I'm sorry ToddBarry! I didnt' see the top answer - I can create a separate ticket and give you points, if that wil be helpfule
No big deal, but it's unfortunate when someone takes the time to reply and the answer isn't even seen.
Avatar of liltyga

ASKER

nothing personal - I was in a time crunch and was rushing to get the job done- I put in a request with Support to split the existing points or allocate new points. we'll see what transpires.