March 4Mar 4 Hi guys,Need some ideas, or if it's even possible to do what I need.I have a field where I am expecting specific values. Currently, I am using a formula to validate the entry, but the message is general for all conditions.The conditions are: "Only Number Only", "Entry Must be 6 or 5 Characters", "No Duplicate Records Allowed.", and "Entry MUST start with 8, 6, 2 or 1"Is there a way that I can have individual custom messages for each error? ThanksRudy
March 4Mar 4 28 minutes ago, rudym88 said:Is there a way that I can have individual custom messages for each error?Not through the validation mechanism, but you could use a script trigger to precede validation and do your own thing.
March 4Mar 4 Author Thanks,I am experimenting with a script using the "IF" and triggered on exit, but haven't been able to get it to do what I need. Any ideas would be much appreciated.ThanksRudy Edited March 4Mar 4 by rudym88
March 4Mar 4 You should trigger the script OnObjectValidate otherwise validation will occur before the script runs (at least those elements of validation that do not wait until record commit), defeating the very purpose of this exercise.The script itself could be something like:Set Variable [ $errors ; ... ] If [ not IsEmpty ( $errors ) ] Show Custom Dialog [ $errors] Exit Script [ Result: False ] End Ifwith the $errors variable calculated along the lines of:List ( If ( some test ; "some error message") ; If ( another test ; "another error message") ; ... )(Untested) Edited March 4Mar 4 by comment
March 5Mar 5 11 hours ago, rudym88 said:The conditions are: "Only Number Only", "Entry Must be 6 or 5 Characters", "No Duplicate Records Allowed.", and "Entry MUST start with 8, 6, 2 or 1"BTW, I am intrigued what kind of data requires these particular restrictions.
March 5Mar 5 7 hours ago, comment said:BTW, I am intrigued what kind of data requires these particular restrictions.Comment, I ask myself the same questions. This is a database I created to track the time orders take from when they are received at the warehouse to when the truck returns to the warehouse.The data clerks who create the records are making enormous mistakes, e.g., creating duplicate entries by adding digits to the number or changing the order of the digits.I wanted to auto-create the record by pulling data from the ERP, but I can't because FM ODBC isn't compatible with the ERP database.
March 5Mar 5 57 minutes ago, JMart said:The data clerks who create the records are making enormous mistakes, e.g., creating duplicate entries by adding digits to the number or changing the order of the digits.Such mistakes can usually be prevented by adding a check digit to the value, if you can arrange such thing with your data provider.1 hour ago, JMart said:FM ODBC isn't compatible with the ERP database.Have you tried connecting via an API instead (assuming they do provide such thing)?
March 5Mar 5 Author Thanks,I can try with the consultant the "check digit", as per the API I checked with the consultant, Sage does not offer an API. The only way is the read-only ODBC they offer. ThanksRudy
March 5Mar 5 18 minutes ago, rudym88 said:Sage does not offer an API.AFAIK (which is very little to nothing) a REST API is possible through third-party middleware.About ODBC, I wonder if you are approaching it the right way. I have seen a Claris representative tell you it should work provided you do it by querying your ODBC data source using the Import Records or the Execute SQL script step, rather than try to add it as an external data source.
Create an account or sign in to comment