go to post Alexander Koblov · Nov 25, 2020 I think both should be used. If an application needs some privilege for itself (=for all users), e.g. for reading database with code, then this should be role for the application. If different users within same application have different permissions then this should (can) be handled via user roles.
go to post Alexander Koblov · Nov 6, 2020 Hi Ramesh. "Invalid cursor state" is an error returned by ODBC driver. Ensemble just shows this error to you. It's expected that you don't get this error when you run the proc directly on SQL Server -- because there is no ODBC driver involved in this case. What you can try is to run the same query from some other ODBC tool (e.g. WinSQL) and see if you are getting the same error message. If you see the same problem -- the likely the issue is within ODBC-driver+SQL Server. If you don't see the same problem then indeed, something might require changing on Ensemble side. Also -- try googling this error message "Invalid cursor state". As this error message comes from Microsoft ODBC driver there are perhaps discussions on Microsoft sites. For example, I found this one https://social.msdn.microsoft.com/Forums/en-US/f6466a82-caf7-4053-94a4-a...
go to post Alexander Koblov · Sep 15, 2020 I also don't know if this is fixed. Studio is backwards compatible, so you can try to use Studio from Caché 2018.1.4 to connect to Caché 2017.1 or Caché 2017.2 instance. Or you even can try to use IRIS Studio 2020.1
go to post Alexander Koblov · Sep 14, 2020 In Studio if you open Watch view and select Call Stack tab and then select particular line then in the right part you'll see variables for current stack
go to post Alexander Koblov · Aug 18, 2020 Hi Yone. Notice -- 4th argument is status code of conversion: ENSDEMO>set fecha = "2021-08-18T07:44:14.180+0000" ENSDEMO>set nuevaFecha = ##class(Ens.Util.Time).ConvertDateTime(fecha,"%Y-%m-%d%T%H:%M:%S","%d/%m/%Y",,.status) ENSDEMO>zw status status="0 "_$lb($lb("<Ens>ErrGeneral","Extra text 'T07' not parsed before end marker ':'",,,,,,,,$lb(,"ENSDEMO",$lb("e^zParseDateTime+102^Ens.Util.Time.1^2","e^zConvertDateTime+3^Ens.Util.Time.1^1","e^^^0")))) Adjust format and you'll get expected value: ENSDEMO>set nuevaFecha = ##class(Ens.Util.Time).ConvertDateTime(fecha,"%Y-%m-%dT%H:%M:%S.%N%z","%d/%m/%Y",,.sc) ENSDEMO>write nuevaFecha 18/08/2021
go to post Alexander Koblov · Aug 11, 2020 David, JDBC Gateway is used when IRIS needs to connect to 3rd party database via JDBC. If you or your customers need to connect to IRIS via JDBC -- then JDBC Gateway is not needed. Just use superserver port.
go to post Alexander Koblov · Aug 3, 2020 Dismount/mount database invalidates cache for the globals from this database.
go to post Alexander Koblov · Jul 31, 2020 You can redirect results to the file. If you specify csv format then data is TAB-delimited. SAMPLES>>set displaymode=csv displaymode = csv SAMPLES>>set displaypath=c:\temp\ displaypath = C:\temp\ SAMPLES>>set displayfile=results.txt displayfile = results.txt SAMPLES>>select * from Sample.Person 4. select * from Sample.Person C:\temp\results.txt.csv C:\temp\results.txtMessages.txt
go to post Alexander Koblov · Jul 20, 2020 Hi Lucas. I'm confused in the URL on the screenshot you are correctly using IRISUsername [0] Why in the "sudo google-chrome-stable ..." command you are using just "Username" parameter? Did you redefine GetCredentials to take username from URL parameter "Username" ? [0] https://docs.intersystems.com/irislatest/csp/docbook/Doc.View.cls?KEY=GC...
go to post Alexander Koblov · Jul 9, 2020 Check if you have CryptoPro. If you have -- uninstall it, then install Caché, then install CryptoPro back
go to post Alexander Koblov · Jun 25, 2020 You need to specify number of parameter in the variable: s Args=10 See my original example
go to post Alexander Koblov · Jun 25, 2020 This works both way. Consider class: Class dc.TestArgs { ClassMethod AcceptArgs(x...) { write "Got following params",! zw x } ClassMethod NormalMethod(a As %String, b As %String, c As %String) { write "we got in a: ",a,! write "we got in b: ",b,! write "we got in c: ",c,! } ClassMethod SendArgs() { set p = 3 set p(1) = "first parameter" set p(2) = "second" set p(3) = "third" do ..AcceptArgs(p...) write "works with usual argument style",! do ..NormalMethod(p...) } } Notice in SendArgs we are constructing p -- array of arguments. We can pass it both to method that accepts args..., and to normal method. USER>d ##class(dc.TestArgs).AcceptArgs(1,2,3) Got following params x=3 x(1)=1 x(2)=2 x(3)=3 USER>d ##class(dc.TestArgs).SendArgs() Got following params x=3 x(1)="first parameter" x(2)="second" x(3)="third" works with usual argument stylewe got in a: first parameter we got in b: second we got in c: third
go to post Alexander Koblov · Jun 11, 2020 I don't like 'isc'. It was (is) sometimes used as an abbreviation for "InterSystems Corporation". So that does not indicate clearly that package comes from Community. 'community' is fine. It's not too long.
go to post Alexander Koblov · Jun 11, 2020 you need to specify SSLConfiguration property of %XML.Reader that points to valid SSL configuration to be used to access https://www.musicxml.org [1] Or you can just disable entity resolution: Disabling Entity Resolution [1] https://cedocs.intersystems.com/latest/csp/documatic/%25CSP.Documatic.cl...
go to post Alexander Koblov · May 27, 2020 I would look for errors in javascript console (Web Developer tools). Also I would double-check if database HSTMDATADEV indeed has packages, based on its name it looks like it could have only data, and there is also HSTMCODEDEV where actual packages are stored.
go to post Alexander Koblov · May 20, 2020 Hi Mark. I don't know where "undefined" word comes from on the trace, but when %XML.Reader reads empty element it reads it as character with code 0 -- $char(0), that corresponds to empty string in SQL: Class Community.Test Extends (%RegisteredObject, %XML.Adaptor) { Property StatusLastChecked As %String(XMLPROJECTION = "element"); ClassMethod test() { set xml = "<root><Test><StatusLastChecked></StatusLastChecked></Test></root>" set reader = ##class(%XML.Reader).%New() do reader.OpenString(xml) do reader.Correlate("Test","Community.Test") do reader.Next(.obj) zw obj } } USER>do ##class(Community.Test).test() obj=3@Community.Test ; <OREF> +----------------- general information --------------- | oref value: 3 | class name: Community.Test | reference count: 2 +----------------- attribute values ------------------ | StatusLastChecked = $c(0) +----------------------------------------------------- So in your code you can compare with $C(0). Also for details on handling empty strings, see following section in documentation: Handling Empty Strings and Null Values