see this example to reproduce and explain that there is an unnecessary conversion on the way
.png)
as you showed in your example
"text": "Condição de pagamento sujeito a análise de crédito: "
- Log in to post comments
see this example to reproduce and explain that there is an unnecessary conversion on the way
.png)
as you showed in your example
"text": "Condição de pagamento sujeito a análise de crédito: "
@Rubens Silva
That sounds to me like double encoding.
I'd suggest using a HEX Editor (e.g. PSpad) to examine your files.
UTF-8 means that some characters have more than 8 bit.
By converting an already converted string you may get those strange effects.
And you found the way to avoid this already yourself.
I just tested a variable parameter list in SQL. It works: (simplified example)
with SQL:
so you can generate your JSON straght as ClassMethd
With 2013.* it is not built-in, but you can mimic it:
every Classmethod can be projected as SQLprocedure.
I'm not sure if you can pass a variable list of arguments from SQL.
But this is the basic mechanic behind it
check SQL Function JSON_OBJECT
https://cedocs.intersystems.com/latest/csp/docbook/DocBook.UI.Page.cls?KEY=RSQL_jsonobject
and JSON_ARRAY
https://cedocs.intersystems.com/latest/csp/docbook/DocBook.UI.Page.cls?KEY=RSQL_jsonarray
with the related examples
Based on the changed question you may consider this solution with just 1 Common Class:
If you look to the Storage definition you see something similar:
Now you change the <Global> node to
this means if there is no variable %GLOBAL you see ^tabA but if you set %GLOBAL you see ^tabB
to set the variable also directly from SQL you may add this ClassMethod as SQLprocedure
now see the effect. first the test data:
and now the SQL query
next with pure SQL
The SQL procedure SetGlobal is independent of the rows:
It will be processed before the row selecting. So we set our local variable %GLOBAL there.
As it is part of the WHERE clause we have to check the return value.
So it works with any SLQ Query tool. eg. Mgmt Portal.
Setting the variable works of course also for object access.
instead of the explicit global you may try to use global name indirection.
Suggestion: Use a %variable to escape from scoping troubles.
see details : Subscript Indirection and $NAME function
Yes it is.
I missed it and entered via registration.
JOIN THE WEBINAR!
you may take this example from OpenExchange:
https://openexchange.intersystems.com/package/Light-weight-EXCEL-download
Al you have to do is to out-comment in
this line :
and the table goes to your browser.
you have to mimic %Next() as %session.Data is a Multidimensional Array)
COS is the acronym for Caché Object Script.
It is the oldest programming language in Caché , Ensemble, ... .
BTW. Your new approach looks promising and safe.
A native COS example is available in Open Exchange now.
WebSocket Client Demo in IRIS 2020.1
If I understand you correct you expect something like
INSERT INTO new.MESSAGE (SELECT * from EnsLib.HL7.Message where id = ? )
this may work for rather modest designed relational tables but I doubt it will work for some complex structure as EnsLib.HL7.Message .
Subclassing is not the way to solve your problem for 2 reasons:
There are ways to do something like this if you fiddle around in the storage structures.
BUT: for reasons of transparency, documentation, and maintainability
I'd strongly recommend to use DTL.
Fiddling around with COS in Ensemble is a rather tricky exercise.
Based on practical experience I can confirm that your successors will never forget you.
IRIS 2020.1 !!!
Ok It works in IRIS 2020.1 (e.g against
The attempt of a backport failed for IRIS 2019.1 and Cache2018.1.3
There seem to be more serious changes than just the client code itself.
you are fully right.
I just checked in Class Reference:
stream class %CSP.CharacterStream extends %GlobalCharacterStream, %CSP.Stream
I started with %Stream.GlobalBinary, ... wondering what the problem might be.
Thinking over ENSEMBLE I moved to %GlobalBinaryStream
@Tomas Vaverka
Ahoi, can you watch my local terminal from remote?
You describe pretty much my investigation! ![]()
Hi Jenna,
I took some time to verify my suspicion. (Caché 18.1)
You depend on the type of stream that is used in your object
#A) %Library.GlobalBinaryStream or %Library.GlobalCharacterStream
Which seems to be your case ![]()
![]()
it's not a big surprise as ENSEMBLE may still use the old style.
#B) using %Stream.GlobalBinary, ...
Not as string.
Parameters are stored as sub-object with the class object in %Dictionary.* classes.
And serve as Information for the code to be compiled.
Great !
Did you try a backport to Caché (18. or so) ?
PARAMETER and DISPLAYLIST are both compiler directives and you can't mix them.
But you may workaround it by writing your own pair of DisplayToLogical / LogicalToDisplay ClassMethods for this property´.
Hi Nigel,
About a year ago a faced a similar problem and found 2 possible workarounds.
Instead of writing a WS client a delegated it out to JavaScript.
#1) Using CSP
#2) my preferred one with node.js
Both examples are available on OpenExchange
as Websockets ar so natural to JavaScript the result is no rocket science.
Stay healthy
@Julius Kavay is fully correct.
The compiler was first written ~10 years before the idea of LLVM started @ University of Illinois.
Various interfaces allow your development very close to the data store.
I'd suggest you contact your Sales Engineer @ InterSystems (Darmstadt ?) for disclosure of internals.
Guess this comes from Cut/Paste
And keep the cooking description for your future updates
The official way is to log an ENHANCEMENT REQUEST at WRC portal.
And wait.
it is an IRIS export
while for Cache it ooks like this:
<?xml version="1.0" encoding="UTF-8"?>
<Export generator="Cache" version="25">
it might be sufficient to change 26 to 25 to make your Caché happy
You don't have a great chance, but you may dig it down like this
And I assume once seen you get your display faster than this cycles where I had no idea on the subscript structure before
.png)
.png)
.png)
.png)
to estimate the age of ^%G take a look to copyright
.png)
.png)