Robert Cemper · Jan 19, 2024 go to post

from my local Class docs:

GetGlobalSizeBySubscript
This method will return the size of a global based on the number of database blocks the global resides in.

so you get blocks * blocksize ===> ALLOCATED size
Depending on Packing as %GSIZE shows   The difference might be significant

Summary by Subscript will most likely show higher values as a pointer block
or even a data block (eg. with 8kb) may contain more than a single subscript
depending on the Global structure.
Take the default top subscript  (aka. IDKEY) for Caché classes (Integer, >0) as an example ​​

Robert Cemper · Jan 19, 2024 go to post

tSC is mostly a %Status object
with enough experience Zwrite tells you all you want and need to know
$SYSTEM.Status.DisplayError(tSC) is easier read.  a matter of comfort

Robert Cemper · Jan 19, 2024 go to post

ChatGPT is just stupid and has no idea of IRIS / Caché
A TABLE will by default never have the same name as the GLOBAL that stores the content
>>>> HS.IHEX.RecordHistory and the global ^HS.IHEX.RecordHistory  <<<<<
HS.IHEX.RecordHistory is definitely not a handcrafted table.

Robert Cemper · Jan 19, 2024 go to post

Thanks for the recognitions!  😀🖐
It's a very strong motivation to be productive.
Often to distract from personal struggles.
Many thanks to the DX+OEX+GM team for their help! 👏 🌸🌼🌹🌻💐

Robert Cemper · Jan 19, 2024 go to post

Hi @Daniel Aguilar 
for every DB you have a default collation that is tied to DB:
you can see it in SMP  System > Configuration > Local Databases > Database Properties

this is the standard.
If the collation of your source server is Spanish, German, Fench, , .... 
the DB may have used this national collation as default.
On your target serve you need to have this collation to be installed.
in SMP  System > Configuration > Locale Definitions you see what is installed on your Caché instance

You may need to add the missing collation table to your Caché instance:



 

Robert Cemper · Jan 16, 2024 go to post

in the previous screenshot you see the namespace as a blue link
and the names of the DB in the yellow highlighted  
 

Robert Cemper · Jan 15, 2024 go to post
  •  iristerm does NOT support ssh
  • you need to run ( + install ?) a SSH service in your  Linux SUSE 15 VM 
  • next, you connect from Win10 over any SSH terminal client (e.g. Putty, ...) to your SuSe VM console command line
  • there you can run iris session ...........  (the Linux equivalent of iristerm)

Just as described in your question

Robert Cemper · Jan 12, 2024 go to post

check if the date object  var d=new Date();
is inside your routine or at least globally defined

Robert Cemper · Jan 12, 2024 go to post

take a look to Mgmt Portal and check NAMESPACE definition
to see DB-file vs. Namespace.
In your case, I'd create a new namespace based on your DB-file to avoid conflicts.
>>> the same Db for Routine (=code) and Globals

Robert Cemper · Jan 11, 2024 go to post

Big CONGRATULATIONS to all winners !
It's a pleasure to follow your contributions.

Robert Cemper · Jan 8, 2024 go to post

%Studio.Project).InstallFromGbl(...  rejects explicitly for Versions before 2013.1 in line 1440

  • ...   ("VERSION")),".",1,2)<2013.1  ..... 
  • ...  Set sc=$$$ERROR($$$DplyVersion, .....
  • %occErrors.inc(2547): #define DplyVersion 7602

You better contact WRC for help  with this 10 year old version

Robert Cemper · Jan 5, 2024 go to post

Bonsoir Sylvain!
Are you looking for something similar to this;
 

Property MonJour As %String 
     [ InitialExpression = "31/12/1840" ];

Property Jour As %Date [ InitialExpression = 0,
  SqlComputeCode = {set {*}= $ZDH({MonJour},4) },
  SqlComputed, SqlComputeOnChange = MonJour ];
 

(Multiline just for readability)
 

Robert Cemper · Jan 5, 2024 go to post

Thanks for the test data!
It confirms known behavior:

  • Oracle takes a lot of effort to prevent straightforward comparisons
  • But over decades, I haven't ever seen them winning against IRIS / Caché.
  • OK, and PostgreSQL or MySQL never was competitive,

Great job !

Robert Cemper · Jan 3, 2024 go to post

#1)  what type of "routine" do you try to handle ?

  • .cls
  • .mac
  • .int
  • .obj

#2) what is the Format you get those "routines"

  • .ro
  • .xml
  • .udl

some combinations may allow  "command line" examination 

Robert Cemper · Jan 3, 2024 go to post

there is a basic misunderstanding:

inside the <CSP:WHILE...> block you are in HTML context
but you issue instead JavaScript >>>> which just prints it out.
To illustrate this see this simple example:
But changing to JS_context solved my simple demo with alert();
 

<csp:WHILE CONDITION="resultSet.Next()">     

 <!-- xValues.push(#(resultSet.Get("StatsDate"))#)
  yValues.push(#(resultSet.Get("Value"))#) -->
  
 <p>#(resultSet.Get("StatsDate"))#<br>#(resultSet.Get("Value"))#</p>
 
 <script LANGUAGE="JavaScript">
 alert(#(resultSet.Get("StatsDate"))#+'>>>'+#(resultSet.Get("Value"))#);
 </script>

</csp:WHILE>
Robert Cemper · Dec 29, 2023 go to post

Great Stuff!
This matches seamlessly to the  "real" Customer benchmark I did in 2009 (with Caché)
against PostgreSQL and MySQL
Years went by but the principles haven't changed.

  • keep memory consumption low
  • data transfer between memory and "disk" (or what mimics a disk) is the
    the slowest component of your system (except human user) so keep it as flat as possible

Glad to see that this is still as valid as it was since ever.
After so many years, all new technology tricks didn't change that.

Robert Cemper · Dec 26, 2023 go to post

It is still in IPM. OEX seems to have lost it.  ???
 

zpm:USER>search global-dump-sql
registry https://pm.community.intersystems.com:
global-dump-sql 1.0.2
zpm:USER>install global-dump-sql
 
[USER|global-dump-sql]  Reload START (C:\InterSystems\IRIS\mgr\.modules\USER\global-dump-sql\1.0.2\)
[USER|global-dump-sql]  Reload SUCCESS
[global-dump-sql]       Module object refreshed.
[USER|global-dump-sql]  Validate START
[USER|global-dump-sql]  Validate SUCCESS
[USER|global-dump-sql]  Compile START
[USER|global-dump-sql]  Compile SUCCESS
[USER|global-dump-sql]  Activate START
[USER|global-dump-sql]  Configure START
[USER|global-dump-sql]  Configure SUCCESS
[USER|global-dump-sql]  Activate SUCCESS
 
Just providing the global name results in a full global dump.
Example:
USER>zn "user"
IRISAPP>d $system.SQL.Shell()
SQL Command Line Shell
... select TOP 5 * from zrcc_G.dump where zrcc_G.Dump('^%SYS','"JOURNAL"')=1
 
Robert Cemper · Dec 25, 2023 go to post

Thank you Maksym !
You reached 100% ObjectScript.
I was really impressed by your Part2 on day 23 + 24

Robert Cemper · Dec 25, 2023 go to post

Hi all,
All challenges of AOC 2023 are published.
You are invited to publish your solutions before Dec.28th:
I'll clone your repos on early Dec 28th. no late coming.

  • To be clear only ObjectScript is accepted, no embedded Python or other
  • Testing is done with IRIS for Windows (x86-64) 2023.2 (Build 227U)
  • Docker containers are not part of this check.
  • No problem If you don't have all solutions you just rank later 
  • My personal special thanks go to the 4 participants, that helped me to set up the test methods.

Actual ranking by verified completion in ObjectScript
 

  • DCrank  AOCrank Scores  Stars   ok%     ----- Code Parts OK -----       Name
    0       ---     ----    ----    ---     ----*----*----*----*----*       --- DC Members ---
    1       1       6825    50      100     3333333333333333333333333       Kevin An
    2       2       6812    50      100     3333333333333333333333333       maxymczech
    3       3       6697    50      100     3333333333333333333333333       Yuval Golan
    4       13      4646    36      74      3333333331313333--111311-       Oliver Wilms
    5       14      4305    35      70      3333333333313133-1111--1-       Ivo ver eecke
  • UTC 2023-12-25 18:52:18
  • EST 2023-12-25 13:52:18  
Robert Cemper · Dec 21, 2023 go to post

A great initiative. A really surprising experience to see the echo of the community.
for those interested in details without personaö self-promotion.

Best wishes - especially HEALTH -- to everyone in the community
And special thanks to the excellent team running this community. 💐🌺🌹🌼🌻🌟

Robert Cemper · Dec 19, 2023 go to post

If you want to clear all old data you have to use  ..%DeleteExtent(..) that you inherit from %Persistent.

Changing from %Persistent  to %SerialObject is a compiler-related action.
The compiler doesn't take care of your storage.
In this case only the access methods change, but not the underlying storage and its content