Question Pravin Barton · Feb 14 How to get IPM module name from source directory For some build scripting with the InterSystems Package Manager, I'd like to first uninstall a package with `zpm "uninstall"` and then load it from disk using `zpm "load"`. That way anything that got deleted from the source will also be deleted from IRIS. The problem is that `zpm "uninstall"` takes in a module name and I only have the directory path to the package source. Is there a way to get the module name for an installed IPM module given the source path? It's okay to assume that it has previously been installed from that same directory with `zpm "load"`. #InterSystems Package Manager (IPM) #InterSystems IRIS 0 1 0 36
Question Pravin Barton · Apr 25, 2024 Possible to export a class without specific members? Is there a way to exclude specific members from a class when exporting to an XML or UDL file? Bonus question: is there a way to import from that file without overwriting those members that were excluded? The use case is to export an interoperability production class without the ProductionDefinition XDATA. We plan to source control the production items through the Ensemble Deployment Manager, but we still need to export any custom code in the class definition itself. #Interoperability #ObjectScript #Ensemble #Health Connect #InterSystems IRIS #InterSystems IRIS for Health 0 3 0 143
Question Pravin Barton · Sep 12, 2023 How to exclude folders from VS Code ObjectScript search I have a VS Code workspace using server-side editing with separate folders for different namespaces on the instance: #VSCode 0 3 0 549
Question Pravin Barton · Apr 18, 2023 Allow string or number values for a property with JSON adaptor I have a class using the JSON adaptor: Class pbarton.test Extends (%RegisteredObject, %JSON.Adaptor) { Property Version As %String; } The Version property could be either a string or a number in the JSON source data. If it's a string, importing it will succeed. If it's a number, importing fails. #JSON #InterSystems IRIS 0 1 0 297
Question Pravin Barton · Apr 7, 2023 How can I change the default string collation of a SQL stored procedure? On an IRIS system, we expect the default string collation for SQL columns to be SQLUPPER. This means WHERE conditions will be case-insensitive. However, when I make a WHERE condition on a SQL procedure that returns a string, it's case sensitive.For example: #SQL #InterSystems IRIS 0 2 0 352
Question Pravin Barton · Aug 11, 2022 How to get IP address of client calling SOAP web service I have a SOAP web service on an IRIS system. From within the code of the WebMethod I would like to log the remote IP address of the client. Is there any way to get access to the client's IP address from the ObjectScript code in the SOAP service? This will save me some headaches correlating logs from IRIS with web server logs. #SOAP #InterSystems IRIS 0 2 1 725
Question Pravin Barton · Jun 14, 2021 How to deal with rate limiting in a Business Operation I'm working with a REST API that will sometimes rate limit our requests by returning an HTTP 429 Too Many Requests status code. Is there a good way in a business operation to handle this by throttling our requests until we get a success response? My initial thoughts are: #Business Operation #Interoperability #InterSystems IRIS 0 1 0 309
Question Pravin Barton · Aug 23, 2019 Testing interoperability productions without connecting to external systems Hello all, I'm trying to write tests for an interoperability production using %UnitTest.TestProduction. I'd like to control the behavior of the SOAP operations so they don't actually connect to external systems when I'm testing. My first thought for this is to create a mock outbound adapter class that answers with some configured class method: #Interoperability #Ensemble 0 4 1 286
Question Pravin Barton · Apr 3, 2019 Best way to document a SQL view I use Documatic a lot to generate class documentation from comments embedded in the code. Is there a good way to create documentation for SQL views as well? Ideally I want to document each column in the view with HTML markup similar to how I document each method of a class with Documatic. #ObjectScript #SQL #Caché #InterSystems IRIS 0 2 0 613
Question Pravin Barton · Nov 20, 2018 How to XML project a Boolean/Integer property as an empty element For each instance of an XML-enabled class I want to control whether a property is projected as an empty element or not projected at all. With string properties, I can set the value as $c(0) for an empty element, or an empty string for no projection. But it looks like this isn't consistent for properties with type %Boolean or %Integer. With booleans $c(0) gets projected as "false". With integers $c(0) stays as a zero-width space in the XML output (which gives me a SAX parser error if I try to read it).Is there a way to do this that works for all datatype properties? #Object Data Model #XML #Caché 0 2 0 614
Question Pravin Barton · Sep 6, 2018 Using Caché OAuth 2.0 authorization server with password grant I'm using Caché as an OAuth authorization server and I want to accept the password credentials grant type. I've found that if I make an authorize request, the Caché authorization server requires some URL parameters that shouldn't be required in password grant (redirect_uri, state, scope, and response_type). If I include these parameters, it calls my DirectLogin() method instead of just calling ValidateUser() as I would expect from the docs. I have two questions: #Caché #OAuth2 1 3 1 712
Question Pravin Barton · Apr 2, 2018 Link method of %CSP.Page doesn't add query parameters The Link() method of %CSP.Page claims to take a link and an array of query parameters and transform them into a URL. The documentation is here. But when I pass in query parameters, they aren't included. #CSP #Caché 0 1 0 459
Question Pravin Barton · Jan 31, 2018 How to assign unique IDs to rows in the product of a table join This might be more of a math problem than a Caché question.I have a SQL query that joins two tables. I want to assign a unique ID to each row of the product table. #SQL #Caché 0 12 0 1.7K
Question Pravin Barton · Oct 30, 2017 How to put a character limit on a textarea? I want to limit the length of the value of a textarea in Zen. In HTML the textarea element has a 'maxlength' attribute, but the Zen component doesn't have an equivalent property. Is there any way to add a maximum length in Zen short of creating my own custom component? #ZEN #Caché 1 3 0 702
Question Pravin Barton · Aug 1, 2017 Disable journaling on an Ensemble data purge I'm purging a lot of management data from an Ensemble production, which is creating 100s of GBs of journals. Has anybody succeeded in disabling journaling on an Ensemble purge? The user interface doesn't have an option for this, but I'm thinking you might be able to identify the process and externally disable journaling on it. #Ensemble #Journaling 0 3 0 939
Question Pravin Barton · May 24, 2017 How to include a macro file in a CSP page I'd like to include a .inc file in a tag-based CSP page. The include file defines a bunch of macros that I want to use in CSP runtime expressions. Is there any way to do this? #CSP #Caché 0 3 0 490
Question Pravin Barton · May 3, 2017 Unable to open HTML files from Atelier server explorer When I try to open an HTML file from the Server Explorer, it fails with the error message "Failed to create the part's controls". HTML files open without any problem from the Atelier Explorer.Has anyone else had this problem? 0 5 0 304
Question Pravin Barton · May 2, 2017 How to get a permalink to a specific comment It would be nice if there were a permalink displayed for each comment. That way I could bookmark or send a link to a specific comment. I can see links to my own comments in the My Account page, but I don't see any way to get permalinks for other people's comments. #DC Feedback 0 3 0 217
Question Pravin Barton · Jan 20, 2016 Use an array as a SQL parameter for a Zen tablepane? I'd like to have an array as a parameter for a SQL 'WHERE... IN' statement. The array would be modified in javascript on the browser. Here's a simplified example: #SQL #Frontend #ZEN #Caché 1 2 0 452