Question Timothy Leavitt · Dec 5, 2016 Incorrect page title on profile "Answers" tab On my "Posts" page (https://community.intersystems.com/user/10056/posts), the title is "Posts (#)".On my "Comments" page (https://community.intersystems.com/user/10056/comments), the title is "Comments (#)".On my "Answers" page (https://community.intersystems.com/user/10056/answers), the title is "Evgeny Shvarov": #DC Feedback 0 3 0 209
Question Timothy Leavitt · Aug 17, 2016 What is the best pattern for reporting errors from an SqlProc? Given a complex method flagged with [ SqlProc ] so it is available as an SQL stored procedure, what's the best way to report a non-system error detected in that method - say, for example, an error %Status - so that the SQL query calling it fails descriptively? Is it best to create and throw an exception, or are there special % variables involved (like in a trigger)? I haven't been able to find an answer in the documentation. Thanks in advance! #SQL #Caché 0 2 0 426
Question Timothy Leavitt · Jul 8, 2016 Best way to compare two arrays for "equality" (same subscripts and values) I've been trying to write a method to compare two local variables, which may be arrays, for "equality" - that is, to see if they have all the same subscripts (if they're arrays) and values. This is the best I've come up with so far - are there any better/simpler approaches out there? #Code Snippet #ObjectScript #Caché 3 6 0 1.5K
Question Timothy Leavitt · Mar 2, 2016 What determines the value of $$$DefaultLanguage (used for localization) for a new Caché installation? Is the default language (i.e., $$$DefaultLanguage, which is used as the basis for localization with $$$Text/etc. at compile time) always "en" for new Caché installations, or could it be different? How is this determined? I don't see an option to select a language during Caché installation. Also, is there a supported/preferred API for setting the default language? Looking at %occMessages.inc, one option would be: #Compiler #Databases #Globals #Localization #Caché 0 3 0 540
Question Timothy Leavitt · Feb 11, 2016 Merging two %Objects (2016.1/2016.2) I'm revisiting some older projects that can benefit from the new JSON support and dynamic object capabilities in 2016.1 FT / 2016.2 FT. (Particularly, some of the really new features in the latest 2016.2 FT.) For the particular thing I'm working on, it would be very handy to be able to merge objects, similarly to https://api.jquery.com/jquery.extend/. The closest thing I've found so far (in 2016.2 only) is: Set o1 = {"a":1,"c":2}, o2 = {"b":1,"c":1} Write "o1: ",o1.$toJSON(),! #Caché #JSON 0 1 0 574
Question Timothy Leavitt · Feb 9, 2016 Property with SqlComputed and SqlComputeCode, but not Calculated or SqlComputeOnChange Looking at a property defined as follows: #Object Data Model #ObjectScript #SQL #Caché 1 4 0 760