Ugo DI LUCA Posted February 14, 2003 Posted February 14, 2003 In order to prevent users to create new account for existing clients, I already had "installed" a find duplicate using a seljoin Clients:g_name :Clients:name. But obviously, ABC & A.B.C aren't duplicate, nor FA.MI.LY & FAMILY. My first thought was of using a calculation for a new "multikey" global field, using a looping script to set the multikey with an "Insert Calc result"... But as it could also be F.AMILY, FA.MILY, FAM.ILY, FA.M.LY,..., I'm sure there is another way I cannot think about. 1. Is there another way ? 2. What would be this calculation like - I'm stuck with Left("."...) ? Thank you very much.
Lee Smith Posted February 14, 2003 Posted February 14, 2003 Hi Ugo, If it is only the periods "." that are the problem, why not incorporate a substitute(yourfield, ".", "") into the find for duplicate. You could also gang up this to include other problem characters such as "-" Substitute(Substitute(Substitute(yourfield, ".", ""), "-",""), ",","") HTH Lee
Ugo DI LUCA Posted February 14, 2003 Author Posted February 14, 2003 Hi Lee, After some thinking, I came up with that too.You're right for the "-" as this is also a parameter. Thanks a lot. Here is what I have in mind right now. Here are the fields in Clients n_Name g_Name c_NameAbbrev = Substitute(Substitute(Substitute(n_Name, ".", ""), "-",""), ",","") c_gNameAbbrev = Substitute(Substitute(Substitute(g_Name, ".", ""), "-",""), ",","") New relationship would be When a new entry is processed, using the "New Entry Layout" with global fields, the script search for duplicates using relationship Clients:c_gNameAbbrev::Clients:c_NameAbbrev instead of g_Name:Name that wasn't reliable.
Recommended Posts
This topic is 7952 days old. Please don't post here. Open a new topic instead.
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now