syntax,parameter-passing,intersystems-cache,objectscript
If you use it with indirection as Brandon suggested: TotalArray(ArrName) S Total=0 S K="" F { S K=$O(@[email protected](K)) Q:K="" S [email protected]@(K) } Q Total and then you call it like this W $$TotalArray("^A") or even W $$TotalArray("^A(""someIndex"")") ...
If you open source code for that class (%Dictionary.UDLTextDefinition), you will find CategoryIsValid method, and will see, that only two values are correct now, and it is comment and error. I'm sure you understand category comment. So, error used when developer managed to save source code with syntax errors in...
syntax,parameter-passing,intersystems-cache,objectscript
Only variables local or global, could be passed by reference. For properties it is not possible. You can pass property name as a string, and set value with $property method. And if you need to do it in classmethod or/and in other class, you should pass variable this as well....
intersystems-cache,objectscript
You maybe forgot about %Dictionary.StorageDefintion. set clsDef=##class(%Dictionary.ClassDefinition).%OpenId("User.Test") set storage=##class(%Dictionary.StorageDefinition).%New() set storage.Name="Test" set storage.Type="%CacheSQLStorage" // this is important set storageMap=##class(%Dictionary.StorageSQLMapDefinition).%New() set storageMap.Name="MasterMap" set storageMap.Global="^global" do storage.SQLMaps.Insert(storageMap) set data=##class(%Dictionary.StorageSQLMapDataDefinition).%New() set data.Name="name" set...
intersystems-cache,intersystems
The problem is that Zen doesn't know how to serialize your complex objects, so it can't represent the contents when you move between the client and server. While you can make the objects serializable by extending %ZEN.Component.object, I would recommend that you investigate using the %ZEN.Auxiliary.jsonProvider component in your page...
storage,persistent,intersystems-cache,intersystems
Try making the num, name, type, or pay property required (if there are any that cannot be null). Caché defines the ^kza("mltab","TAB","Dta",1) node because if the other 4 field are all null, the existence of the ^kza("mltab","TAB","Dta",1) node defines the existence of the row. In other words, if num, name,...
Second query correct as well, but wrong target, because, such behavior possible for generated classes. You can see it by non-empty GeneratedBy property in definition for this class. If you try to do it for Sample.Person it will shown correctly. But I still don't understand why you use JDBC, because...
intersystems-cache,objectscript
In first you should check that you send right value for className and paramName, full name and in right case and. Why you choose storage procedures, when you can use select? And you can call your procedure in System Management Portal to see about probable errors. select description, type,_Default "Default"...
intersystems-cache,intersystems,mumps
If you use the class to add data in the global, then you can use the Callback methods. For example %OnAfterSave does what you want. On the other hand if you put data directly into the global then you will need some way to track when data is added. You...
No, it is not possible, because number of columns have to be fixed. But as your code generate result, you can define some columns like Prop1, Prop2...PropN, and in result return as many columns as you need, and any last columns just well be null. And after that in your...
string,string-comparison,intersystems-cache,intersystems,objectscript
It's a bit unclear exactly what you want this string comparison to do, but it appears that you're looking for either the follows ] or sorts after ]] operator. Docs (taken from here): The binary follows operator (]) tests whether the characters in the left operand come after the characters...
Different is in one property. %Dictionary.ClassDefinitionQuery_Summary shows only classes with Deployed<>2. So, sql must be such. select id,super from %Dictionary.ClassDefinition where deployed <> 2 But one more things is, why count may be different is, such sql requests may be compilled to temporary class, for example "%sqlcq.SAMPLES.cls22"...
intersystems-cache,objectscript
If colId for hyperlink property fixed, you can use tag RetrievalCode where possible to write some COS code, if not fixed, you can write something for retreive colId and then like here <Data name="hyperlink"> <RetrievalCode> s {hyperlink}=$g(^myGlob("mltab","main","Dta",{L4},2,"Index")) </RetrievalCode> </Data> and your RowIdSpec maybe wrong, because, property id on 4 level...
intersystems-cache,objectscript
Main limits you can find in documentation. And you can see that, limit for properties is 1000 per class. Maybe you'll check other limits, and will find where you have a trouble.
sql,stored-procedures,intersystems-cache
There are several ways to expose custom query results, they all are mentioned in documentation here: http://docs.intersystems.com/cache20141/csp/docbook/DocBook.UI.Page.cls?KEY=GSQL_procedures As documentation suggests, preferred way is to define each custom query as a separate class using %SQL.CustomQuery class; see Sample.CustomResultSet in the SAMPLES namespace for an example of this approach. You can also...
The problem was that connection config is wrong: QSqlDatabase db = QSqlDatabase::addDatabase("QODBC"); db.setDatabaseName("DRIVER={InterSystems ODBC};SERVER=localhost;PORT=1972;DATABASE=USER;UID=_system;PWD=SYS; Unicode SQLTypes=1;"); it should be: QSqlDatabase db = QSqlDatabase::addDatabase("QODBC3"); db.setDatabaseName("DRIVER={InterSystems ODBC35};SERVER=localhost;PORT=1972;DATABASE=USER;UID=_system;PWD=SYS; Unicode SQLTypes=1;"); ...
And you should add access for concrete table. It is possibble to do for role or for user, in tab SQL tables. Just add table %Dictiinary.Classdefinition To find errors in settings of permissions, you can also use Audit You should add access for table %Dictionary.ClassDefinition from namespace SAMPLES. It is...