go to post Robert Cemper · Aug 28, 2018 set list = $lb("stri,ng", $c(0), 2) ,p=0for set p=$LISTFIND(list,$C(0),p) quit:'p set $LIST(list,p)=""
go to post Robert Cemper · Aug 28, 2018 The path in JSINCLUDES and CSSINCLUDES looks somewhat suspicious to me.you use a path relative to the location of your page.verify (eg. with Chrome) that your libraries really get loaded
go to post Robert Cemper · Aug 28, 2018 you mix up 2 variants of indirection W @B S @("C="_B) These both are ARGUMENT indirections, where the arguments of WRITE or SET are replaced. But S C=@B is a NAME indirection where the name of a variable or global is expected.$P(A,S,2) is definitely no a variable or global name. Docs on Indirection is quite verbose and shows the limits. Most important: this is a runtime feature and not a compile-time feature!
go to post Robert Cemper · Aug 27, 2018 You can achieve this using TRANSACTIONS in combination with ISOLATION LEVELSBUT: as with the LOCK in COS you depend on the other players to take notice of your isolation. If they don't care you are lost since this is no absolute locking.COS has the option to lock your record ahead - but you depend on the other participants.An other option is to use ROWVERSION to protect your record. (optimistic locking)If someone has changed your record under cover you get alerted on the fact.
go to post Robert Cemper · Aug 27, 2018 instead of eXecute you may use Indirectionset @("mylist="_result).It's a matter of taste :take care for ProcedureBlock = 0 ; as for eXecute ; just in case
go to post Robert Cemper · Aug 27, 2018 Only out of curiosity:What do you get back if you just do "return list" without toString() ?Whatever structure CacheListBuilder may have
go to post Robert Cemper · Aug 20, 2018 what about using real ODBC datetime format "2008-09-15 10:00:00" ?
go to post Robert Cemper · Aug 19, 2018 You may create your private row count by group. Class DC.any [ Abstract ]{ ClassMethod MyVid(group = "") As %String [ SqlName = MyVid, SqlProc ]{ if group="" kill %myVid quit 0 ;;initialize it quit $I(%myVid(group))} } .how to use it:SELECT DC.MyVid(company) RowNumber, Company,Company->Name, NameFROM Sample.Employee where DC.MyVid()=0 /* static condition for init */order by 2 .looks like this:RowNumberCompanyNameName11O' KwalLateral Group Ltd.Moon,Mary Q.21O' KwalLateral Group Ltd.Ximines,Alice Z.31O' KwalLateral Group Ltd.Malynko,Greta H.41O' KwalLateral Group Ltd.Lubbar,Emily Q.12InterPlex Holdings Inc.Tesla,Kenny W.22InterPlex Holdings Inc.Jones,Valery N.32InterPlex Holdings Inc.Baker,Samantha D.13GlobaSys LLC.Quixote,Marvin C.23GlobaSys LLC.Xerxes,Violet Y.33GlobaSys LLC.Adams,Kim W.43GlobaSys LLC.Ubertini,Roberta N.53GlobaSys LLC.Jackson,Buzz V.63GlobaSys LLC.Clinton,Keith C.73GlobaSys LLC.Isaksen,Juanita T.83GlobaSys LLC.Solomon,Imelda Z.14SynerMatix AssociatesHumby,Olga A.24SynerMatix AssociatesOrwell,Maureen R.34SynerMatix AssociatesO'Donnell,Ed Q.44SynerMatix AssociatesOrlin,Mary D.54SynerMatix AssociatesVanzetti,Pam V.64SynerMatix AssociatesNoodleman,Chris O.
go to post Robert Cemper · Aug 8, 2018 basis for German was posted here on June 28https://community.intersystems.com/post/translate-number-text#comment-52821
go to post Robert Cemper · Aug 8, 2018 Thanks Ben,that's excellent news. Checkpointing is a feature I was missing already in Caché.I see no urgency in timing yet as we are still a starting phase.
go to post Robert Cemper · Aug 6, 2018 - check available disks space for CACHETEMP (initial size)- check access rights of the account starting Caché
go to post Robert Cemper · Aug 3, 2018 || is the concatenation operator in SQL1||1 results in 11 as you have seen'1||1' in single quotes should do it
go to post Robert Cemper · Aug 2, 2018 for cleaning up: /// to get rid of old versions /// select OBJ.DSTIME_DelVersion('Table',Version) /// ClassMethod DelVersion(Table As %String = " ", Version As %Integer = 0) As %Integer [ SqlProc ]{ Quit:'$l(Table) '$$$OK Kill ^OBJ.DSTIME(Table,+Version) Quit $$$OK}
go to post Robert Cemper · Aug 2, 2018 All I know about python is "Monty Python" OK.The table you want to control needs to get a parameter Parameter DSTIME = "AUTO"; and a recompileThen you can use this class to trace changes, new, delete /// Handle DSTIME using SQL/// select * from OBJ.DSTIME where version = lastversion/// to show allClass OBJ.DSTIME Extends %Persistent [ Final, SqlRowIdPrivate ] {Index idx On (Table, Version, RowID) [ IdKey ];Property Version As %Integer [ ReadOnly, SqlColumnNumber = 2 ];Property Table As %String [ ReadOnly, SqlColumnNumber = 3 ];Property RowID As %String [ ReadOnly, SqlColumnNumber = 4 ];Property Signal As %Integer(DISPLAYLIST = ",Modified,New,Deleted", VALUELIST = ",0,1,2") [Calculated, , SqlComputed, SqlColumnNumber = 5, SqlComputeCode = { set {*}=^OBJ.DSTIME({Table},{Version},{RowID})}];Property LastVersion As %Integer [ Calculated, SqlComputed, SqlColumnNumber = 6, SqlComputeCode = { set {*}=+$G(^OBJ.DSTIME) } ];/// to get actual last version and switch to new version/// select top 1 LastVersion,OBJ.DSTIME_NewVersion(LastVersion) from OBJ.DSTIME/// ClassMethod NewVersion(anycolumn As %String) As %Integer [ SqlProc ]{ Quit $I(^OBJ.DSTIME) }Storage Default {<DataLocation>^OBJ.DSTIME</DataLocation><IdLocation>^OBJ.DSTIMED</IdLocation><IndexLocation>^OBJ.DSTIMEI</IndexLocation><StreamLocation>^OBJ.DSTIMES</StreamLocation><Type>%Library.CacheStorage</Type>} } so get your actual changesselect * from OBJ.DSTIME where version = lastversionand switch to next version by select top 1 LastVersion,OBJ.DSTIME_NewVersion(LastVersion) from OBJ.DSTIME.But you have to have full access to Caché as you have to make the DB "talking" to be able to "listen"
go to post Robert Cemper · Aug 2, 2018 If you have just SQL access you may wrap a class around ^OBJ.DSTIME to select changes
go to post Robert Cemper · Aug 2, 2018 in combination with DeepSee there is a class parameter DSTIME to track additions, changes deletes for this purpose.https://docs.intersystems.com/latest/csp/docbook/DocBook.UI.Page.cls?KEY=D2IMP_ch_current
go to post Robert Cemper · Aug 2, 2018 You have to test on server = "www.intersystem.com" not just domain.443 is ok USER>s req=##class(%Net.HttpRequest).%New()USER>s req.SSLConfiguration="SSL"USER>set sc=req.Get("https://www.intersystems.com")USER>zw scsc=1USER>set data=req.HttpResponse.DataUSER>do data.OutpuToDevice()>>>> lot of content <<<<
go to post Robert Cemper · Aug 1, 2018 There are some mistakes.#1 the links should be "HTTPS://www.intersystems.com" and you didn't set a ssl/tls config.if you use Set sc=httprequest.Get("http://www.intersystems.com",2)Do $system.OBJ.DisplayError(sc)you get ERROR #6159: ===> SSL missing#2 HttpResponse is an ObjectReferce not a Propertyset res=httprequest.HttpResponseZW res res=<OBJECT REFERENCE>[3@%Net.HttpResponse]+----------------- general information ---------------| oref value: 3| class name: %Net.HttpResponse| reference count: 3+----------------- attribute values ------------------| ContentBoundary = ""| ContentInfo = ""| ContentLength = 178| ContentType = "text/html"| Data = "4@%Stream.GlobalCharacter" ;;; here is your reply|Headers("CONNECTION") = "keep-alive"|Headers("CONTENT-LENGTH") = 178|Headers("CONTENT-TYPE") = "text/html"| Headers("DATE") = "Wed, 01 Aug 2018 15:25:05 GMT"|Headers("LOCATION") = "https://www.intersystems.com/"| Headers("SERVER") = "nginx"| Headers("X-TYPE") = "default"| HttpVersion = "HTTP/1.1"| ReasonPhrase = "Moved Permanently"| StatusCode = 301| StatusLine = "HTTP/1.1 301 Moved Permanently"+-----------------------------------------------------The content is in a Stream!! So Write is totally inappropriate to show it. Instead:do res.OutputToDevice() ;;;or similarHTTP/1.1 301 Moved PermanentlyCONNECTION: keep-aliveCONTENT-LENGTH: 178CONTENT-TYPE: text/htmlDATE: Wed, 01 Aug 2018 15:25:05 GMTLOCATION: https://www.intersystems.com/SERVER:nginxX-TYPE: default <html><head><title>301 Moved Permanently</title></head><body bgcolor="white"><center><h1>301 Moved Permanently</h1></center><hr><center>nginx</center></body></html>
go to post Robert Cemper · Jul 30, 2018 You may also want to check your message against the definition in WSDL. (e.g with XMLspy or similar)there are enough SOAP services around that don't fit to the WSDL they publish.
go to post Robert Cemper · Jul 30, 2018 Hi Thomas,If you generate your webservice from a WSDL you should check your classesfor correct hierarchical structure AND for properties flagged as required in WSDL.Typical situation: an address is optional but inside the address, the street is required. This can cause the whole address to be interpreted as required.You may either remove the required in properties or before generating the classes you edit the WSDL ( often easier).