go to post Yaron Munz · Aug 9, 2022 On IRIS 2022.1 the class (%Net.POP3).Connect(...) has a 4th parameter: AccessToken I di not try, but maybe it will allow a connection with OAuth
go to post Yaron Munz · Aug 5, 2022 Cache 2018 support OAuth: https://docs.intersystems.com/latest/csp/docbook/DocBook.UI.Page.cls?KEY...
go to post Yaron Munz · Aug 5, 2022 You may do it programmatically: set mirrorName=$lg(##class(%SYSTEM.Mirror).GetMirrorNames(),1)zn "%SYS"Set result = ##class(%ResultSet).%New("SYS.Mirror:MemberStatusList") Set sc = result.Execute(mirrorName)while result.Next() { s status=result.GetData(9) // get all other info you need from GetData(nnn) }
go to post Yaron Munz · Aug 4, 2022 This is less accurate, Robert. on Leap years it will get "rounded" just a few days before birthday.A workaround this is to divide by 365.25 to get more accurate age
go to post Yaron Munz · Aug 4, 2022 No. I'm not using Laravel. My advice was general, not related to any experience with this product
go to post Yaron Munz · Aug 4, 2022 You have to distinguish between "journals" and "mirror-journals" files. the 1st are to ensure any instance DB integrity (DB corruption) in case of a failure. The 2nd are you ensure proper mirror "failover" and any A-Sync members. When LIVETC01 (as a Backup) is "catch up" its a good source to copy .DAT files to the LIVEDR.It is also safe to delete its mirror-journals.The steps you did to catch up the LIVEDR are correct. (I assume you did "activate" & "catch up" after that in LIVEDR) After the IRIS.DAT copy (of all DBs in mirror) from LIVETC01 to LIVEDR and both are "catch up" - It is safe to delete mirror-journals up to the point of the copy from your primary LIVETC02
go to post Yaron Munz · Aug 3, 2022 Hello, The IRIS management portal is a web application.It connects to the IRIS database with a component called: "CSP Gateway" (can be installed on various web servers: IIS, Apache, Nginx). This "CSP gateway" is enabling you to develop web applications that will interact with the DB directly though this component. You may run "ajax like" code on the server-side, and have all your web pages fully dynamic (generated on the server in run-time).TO work with the management portal from remote, you may take advantage of it's security mechanism (define users, roles, services) the ability to authenticate with external to IRIS entities (e.g. doing LDAP to ADDS) and also have a two-factor authentication, for better security. Any external data database or other tool that can do ODBC & JDBC can communicate with IRIS and get data out of it. Those are also.
go to post Yaron Munz · Aug 3, 2022 Hello, 1. If you mean to Concatenate in SQL than you can use the CONCAT function 2. To get the current date you may use the $ZDATE function (cos) pass the 1st parameter +$H and it will be todays date. 3. To find the DOB based on a date : Set Age = $P($ZD(+$h,3),"-")-$P($ZD(Dob,3),"-")-($E($ZD(+$H,8)5,8)<$E($ZD(Dob,8)5,8))
go to post Yaron Munz · Aug 3, 2022 Hello, I would try to contact the author of the GIT you mentioned, to find out which version of Cache he used and get some help.looks like he was updating the GIT at Apr 10, 2022, so this might indicate that he is active.I saw that he is using a Unix driver "libcacheodbcur6435.so" but I'm not sure which version is this.
go to post Yaron Munz · Jul 18, 2022 To get the "real" start date/time of a sessions, you will have to dig into the ^%cspSession(sessionID) global. you might see a date/time on $LG 20 & 21 (depending on your version)
go to post Yaron Munz · Jul 15, 2022 I recommend that "batch processes" would be run from the Task manager, then if you manage an exact copy of the task definitions (in tasks manager) in your failover, then you do not have to worry (it can be automated with export/import as well) Make sure you have "auto start" enable for your interoperability in case of a mirror failover
go to post Yaron Munz · Jul 15, 2022 Hello, as the documentation is saying, the call to %OnSaveFinally() is done at the last step of the %Save() = after data was written to the database, and the transaction is already committed. I did a test with a class: Class USER.TestClass Extends %Persistent{ Property Name As %String; ClassMethod %OnSaveFinally(oref As %ObjectHandle, status As %Status) { S ^TestGlobal="This is a test "_$ZDT($H) } } Then, I've saved some new data into the class: USER>s obj=##class(USER.TestClass).%New(), obj.Name="Name", sc=obj.%Save() w !,sc1USER>zw ^USER.TestClassD^USER.TestClassD=1^USER.TestClassD(1)=$lb("","Name") and then checked the journal entries to see the behavior.It shows that the %OnSaveFinally() was called just after a successful save after the CT (close of transaction): 1675920 2312 BT 1675936 2312 S +\iris\mgr\user\ USER.TestClassD = 11675992 2312 ST +\iris\mgr\user\ USER.TestClassD(1) = $lb("","Name") 1676052 2312 CT1676068 2312 S +\iris\mgr\user\ TestGlobal = "This is a test 07/15/202+
go to post Yaron Munz · Jul 14, 2022 Hello Ephraim, your database is 193GB and has 141GB of free space (73% free). There is a 6.5GB space on the OS file system, I recommend you to:- Compact globals in database- Compact free space ibn database- Return free space in database All those can be done when you do the following: USER>zn "%sys"%SYS>do ^DATABASE
go to post Yaron Munz · Jul 14, 2022 I'm using this also after a minor update. It is better to have it like: do $system.OBJ.CompileAllNamespaces("cru") So it will do a recursive compile
go to post Yaron Munz · Jul 14, 2022 Adding a soft delete is a good idea, but then indices will have to be changed as well to support that. If all your 5 places of code are not called, and record are keeping "disappear" then it might be a SQL that is run by a user or developer. I would recommend to : - have an detailed audit on that table/class to see it's deletions- check all ODBC/JDBC users - to see if permissions for delete can be removed- Possibly to have a code to scan journal files, to find that class, global, pid, date time stamp - and store this on a sperate table or global that can be later examined
go to post Yaron Munz · Jul 14, 2022 Hello, The best way it to do it is to use the dictionary to loop on properties of the original class and create a new class which is identical, but with a different storage. The cloning is done by using %ConstructCloneUsually, the new class for backup, does not need to have methods, indices or triggers, so those can be "cleaned" before saving it. Have the original and the destination class objects: S OrigClsComp=##class(%Dictionary.CompiledClass).%OpenId(Class)S DestCls=OrigCls.%ConstructClone(1) You should give the destination class a name and type: S DestCls.Name="BCK."_Class , DestCls.Super="%Persistent" Usually the destination class does not need to have anything than the properties, so in case there are methods, triggers or indices that need to be removed from the destination class, you may do: F i=1:1:DestCls.Methods.Count() D DestCls.Methods.RemoveAt(i) ; clear methods/classmethodsF i=1:1:DestCls.Triggers.Count() D DestCls.Triggers.RemoveAt(i) ; clear triggersF i=1:1:DestCls.Indices.Count() D DestCls.Indices.RemoveAt(i) ; clear indices Setting the new class storage: S StoreGlo=$E(OrigCls.Storages.GetAt(1).DataLocation,2,*)S StoreBCK="^BCK."_$S($L(StoreGlo)>27:$P(StoreGlo,".",2,*),1:StoreGlo) S DestCls.Storages.GetAt(1).DataLocation=StoreBCKS DestCls.Storages.GetAt(1).IdLocation=StoreBCKS DestCls.Storages.GetAt(1).IndexLocation=$E(StoreBCK,1,*-1)_"I"S DestCls.Storages.GetAt(1).StreamLocation=$E(StoreBCK,1,*-1)_"S"S DestCls.Storages.GetAt(1).DefaultData=$P(Class,".",*)_"DefaultData" Then just save the DestCls S sc=DestCls.%Save()
go to post Yaron Munz · Jul 12, 2022 I recommend you to check the WebTerminal, which you may connect to VS-Code .. https://intersystems-community.github.io/webterminal/#docs
go to post Yaron Munz · Jul 12, 2022 Hello,i've added an article for using embedded python with ASB (Azure service bus) https://community.intersystems.com/post/iris-embedded-python-azure-servi...
go to post Yaron Munz · Jul 11, 2022 Very nice article Robert. From our experience with Embedded Python (we have a working solution to connect IRIS directly to ASB) we found that it is much faster to pass the Python object to COS and let the COS handle all global activity
go to post Yaron Munz · Jul 8, 2022 Actually I was always using $Zorder ($ZO) which was "invented" 30 years ago, before $Query (popular MSM, DSM etc.)Another thing is that $Order is a "vertical" way of looping through an array/global/PVC and $Query (or $ZO) are meant to loop in a "horizontal" way (same as you ZWRITE it) it has the same functionality, and very easy to use:Set node = "^TestGlobal(""Not Configured"")" W !,node^TestGlobal("Not Configured")F S node=$ZO(@node) Q:node="" w !,node,"=",@node^TestGlobal("Not Configured","Value 1")=value 1^TestGlobal("Not Configured","Value 2")=value 2