go to post Adam Skurek · Jul 30, 2020 s dyn={}d dyn.%Set("asNumber",123)d dyn.%Set("asString",123,"string") w dyn.%ToJSON() {"asNumber":123,"asString":"123"}
go to post Adam Skurek · Aug 12, 2019 Not a problem with the function itself.w 1.00000000000000000011
go to post Adam Skurek · Dec 8, 2018 Is it possible that you added index definitions after you filled the table with data?If that is the case, then those indices are not built ("empty"), and so if the query uses them, then it returns no data. In such case you have to build your indices manually via ##class(MML.Cities).%BuildIndices().
go to post Adam Skurek · Jul 13, 2018 Try Index TagsArrayIndex On (TagsArray(ELEMENTS), TagsArray(KEYS));
go to post Adam Skurek · Jun 13, 2018 I've contacted WRC about this, and their answer is that there is no built-in way.They offered a workaround of enabling unauthenticated access and checking AUTHORIZATION header manually.
go to post Adam Skurek · Nov 10, 2017 Try using iFind indices:http://docs.intersystems.com/latest/csp/docbook/DocBook.UI.Page.cls?KEY=GIKNOW_ifind
go to post Adam Skurek · Sep 29, 2017 Thank you. We are now using Java gateway and we want to replace this with something more native. So it seems that writing own implementation in COS is the only option left. I was hoping that someone has already done that ;)
go to post Adam Skurek · Sep 28, 2017 Thanks, but unfortunately I am unable to find suitable DLL for Win64 with crypt function. I have found 32bit version (GnuWin32/crypt), but it does not work on 64bit environment.
go to post Adam Skurek · Sep 28, 2017 I am trying to generate same output as http://php.net/manual/en/function.crypt.php crypt function (CRYPT_MD5 flavor).So for example$salt=crypt("2Ggaobjb","$1$1a2b3c4d$");returns $1$1a2b3c4d$Y5tt50CQ12xW2saeYnI43, which is not same as pure MD5 hash (like $SYSTEM.Encryption.MD5Hash).From documentation it seems that crypt creates derived hash based on MD5, but it is not the same.
go to post Adam Skurek · Jul 24, 2017 Be careful when using ##Unique. The problems with scope of generated "unique" variable can introduce weird bugs (in some cases it is not as unique as you would expect; WRC problems 879820 and 879901). Citing ISC support from WRC 879820: The problem is that the variable name created by ##Unique is only unique among the set of variables for that method. However, the variable itself is globally scoped. Since the variable name is globally scoped, I think the variable names should be unique for the entire class, not just for the method. I will report this to development. Please note, however, since the variable is globally scoped, using the preprocessor directive as you are here will leak information to any code that calls this class. To prevent this, you should NEW the variable prior to using it: #define A(%x) NEW #Unique(new) SET #Unique(old)=%x Also ##Unique directives cannot be used in nested macros (macro calling another macro; WRC 879901).
go to post Adam Skurek · Jun 6, 2017 Class ITPlanet.Task2 [ Abstract ]{ ClassMethod Main() As %String{q $tr($h,",")} }*You may need to set your date and time settings to 2111-05-30 12:00:10 ;)
go to post Adam Skurek · Apr 13, 2017 Thank you, it seems to work.$SYSTEM.OBJ.Export("WRC.Text.cls","C:\export.xml","/recursive=1")
go to post Adam Skurek · Nov 3, 2016 That function has one nasty feature: If any expression is NULL, GREATEST returns NULL.
go to post Adam Skurek · Nov 3, 2016 ClassMethod Max(args...){ q:(+$g(args)<2) $lb($g(args(+$g(args))),+$g(args)) s max=$g(args(1)) for i=2:1:args { s:($g(args(i))]]max) max=$g(args(i)),maxI=i } q $lb(max,$g(maxI,1))}