25141 results


  • Answer:

    There are good options for what you want available in 2016.2, and possibly better answers for SQL-> JSON after that. In 2016.2, %RegisteredObject also supports $toJSON and $fromJSON, so there won't be any need to use %ZEN.Auxiliary.jsonProvider to ...

    Answer to the post "JSON, Cache and Date/Time" by Timothy Leavitt, 20 April 2016


  • Comment:

    Timothy! Thanks for sharing this!

    It' can be a standalone post as "Error and resource handling in large Caché ObjectScript project".

    Thank you!

     

    Comment to the post "Try catch block I usually use in COS" by Evgeny Shvarov, 16 April 2016


  • Comment:

    Ok, ok, good point about PPG that it will remove reference to the object. And that simple local variable will work better, because it will not serialize OREF to string.

    And the only case when it was workng for me - then the parent call is...


  • Comment:

    >$SYSTEM.Status.GetErrorText(sc)["Something"

    Would not always work correctly in applications with users requesting content in several languages (for example web app). Why not use error codes?

    If $SYSTEM.Status....

    Comment to the post "Try catch block I usually use in COS" by Eduard Lebedyuk, 16 April 2016


  • Comment:

    > you could not implement singleton which will be working across jobs, only for this same process;

    Storing something in %/PPG would not work across jobs too. Singleton is a single-thread anyway.

    > to share instance to teh...


  • Comment:

    How would you have done it? It's 35 lines of code in total, 25 if we remove persistence (because singleton does not actually has persistence, but OP seemed to need it).


  • Comment:

    Here are assumptions:

    - you could not implement singleton which will be working across jobs, only for this same process;

    - to share instance to teh object you could emply %-named variable or process-private global.

    Here is the...


  • Comment:

    OMG! Looks a little bit over-designed


  • Answer:

    A very interesting question. I decided to write a singleton, with the idea that it searches process memory for other instances of this class and returns existing OREF if found. It also stores data in global and retrives it from there on a first load: /// ...


  • Question: SQL Gateway - ODBC Client Caching the Query/SP CALL to the external Database

    SQL, Ensemble Language Undefined Hello,   In my project, I am calling a store proc on third party database. I am using SQL Gateway and ODBC. Everything is working fine until the store proc changed.  In store proc they have changed the return alias name ...

    Post by Raghu Kodumuri 19 April 2016