Question Jose Antonio Cañizares · Mar 5, 2019

Hi all,

Lets imagine that there's a process that locks an entry of a gived domain, in my example the ID 2 of the table User.tApplications and using an exclusive lock.  Additionally the error handling is managed by a $ETrap routine wich will look for error data in order to log it

Set $ETrap = "Do Err1^ErrRoutine"

Set obj = ##class(User.tApplications).%OpenId(2,"4",.errors)

If ($System.Status.IsError(errors){// Error: ERR_PESSIMISTIC_LOCK   Set $ECode = <MyerrorCode>}

When a  second process try to do the same action will cause an error informing that there's a lock (that is ok)

1
0 378
Question Jose Antonio Cañizares · Mar 20, 2018

Hi all,

Does anyone know if a process (which is using a license unit) does an OPEN or USE to send data (to a label printer as an example) through TCP, will result on license slot usage?

If so, will use a new connection of the currently used one by the process or will get a new slot? 

Kind regards

1
0 344
Question Jose Antonio Cañizares · Jul 14, 2017

Hi all,

We faced a problem where we would like to map a $lb object to its corresponding data model structure in order to later on export it as JSON.

So imagin that we have something like this that actually maps to a persistent table with its structure. 

$lb("",,,,,"",,,"BOOLEAN","0",2,2,"1",,"bla",$lb(,,"bla","20050502123400"),"",1,"bla",,0)

Is there a way to transform this $lb (without the need of openig the object itself) to a JSON object with the proper table fields as properties?

Many thanks

9
0 546
Question Jose Antonio Cañizares · Sep 9, 2016

Hi all,

Do anyone know how to force to close the CSP connection used before redirecting to a different page so a new connection ( and therefore a new session id) is generated?

The idea is to generate new CSP session once we log off our application so the session identifiers are different.

Best Regards

4
0 582
Question Jose Antonio Cañizares · Aug 18, 2016

Hi,

We are trying to implement a client side data provider as a component (ZEN) that will use JQuery to do rest calls to a desired URL, in this case, a %CSP.Rest service implemented by ourselves.

This component will be used within our application that is authenticated with a correct user configured on Caché management portal and therefore using one license unit. As we are using a Ajax call from client side this connection creates a new session that will use a new license.

2
0 634
Question Jose Antonio Cañizares · Aug 1, 2016

Hi all,

For custormer support reasons we would like to know if its possible to activate some kind of flag or see/redirect wich is the code (lines) being executed when some misterious problems appear.

Is there any way to view the stack of execution code on a deployed code environment? Is there any other equivalent way to track the execution stack for a certain period of time?

Best regards

5
0 479
Question Jose Antonio Cañizares · Apr 1, 2016

Hi all,

I've been looking for a way to extract the sorting  from the ^CacheTemp.zenData global that contain the tablePane snapshot data in order to use it on a report following the current UI sorting criteria.

I could see that if the column is sorted by one column, new entries with this structure are created:

^CacheTemp.zenData(<sessionId>,<snapShotId>,<tablePaneId>,"index",<columnId>,<value>,<dataId>)=""

6
0 583