Robert Cemper · Dec 12, 2024 go to post

Looking forward to hear your story!
That's often of much more value than the pure code..   

Robert Cemper · Dec 10, 2024 go to post

Somewhere in your data structure you have a property / Column  of type DATE
the content seems to be a null_string (string of length zero) instead of a real SQL NULL (empty, no value)
My guess:  it's one of the 8 Dob ( Date of Birth ?) named fields
check the related contents  
  

Robert Cemper · Dec 4, 2024 go to post

Similar to previous years I will provide the results of our private leaderboard 

  • It will sort by published ranking but separate DC members from "guests"
  • The matching of DC members is a manual task 
  • if I missed you pls. let me know your identity in AoC by DC mail  to add your DC flag
  • due to private issue my updates might show delays sometimes
  • 2 test sets with results are available on OEX: AoC2024-test or GitHub: AoC2024_test
  • I just added a column to show completion of parts in the exercises
    • -  no part
    • 1 only part 1  (silver star)
    • 2 only part 2 (another silver star)
    • 3 1+2 both parts completed (gold star) 
DCrank  AOCrank Scores  Stars   ok%     ----- Code Parts OK -----       Name
0       ---     ----    ----    ---     ----*----*----*----*----*       --- DC Members ---
177361501003333333333333333333333333       abdul-manaan
287296501003333333333333333333333333       Yuval Golan
39531036723333333333333331331------       JFerreB
41125981836333333333----------------       Peter Zubiago
51325371734333333331----------------       Oskari Kosonen
614205214283333313---1--------------       Keith Avery
715192813263333331------------------       Jani Hurskainen
81716391122333311--1----------------       Ivo ver eecke
918127891833331--------------------       TylerFeldhege
1021875612333----------------------       rhodery
1123695510331----------------------       Chris Marais
12245654833-----------------------       Oliver Wilms
13      ---     ----    ----    ---     -------------------------       --- ISC internals ---
1427592501003333333333333333333333333       TestSet 11537545501003333333333333333333333333       TestSet 21622811612333----------------------       Junhee Lee
17      ---     ----    ----    ---     -------------------------       --- unknow in DC ---
1817683501003333333333333333333333333       Dominik Znidar
1947540501003333333333333333333333333       Joaquin Derrac Rus
2057539501003333333333333333333333333       Jarjar 3142167527501003333333333333333333333333       (anonymous user #1128565)
2210329523463333313-1331311----------       (anonymous user #4293990)
23122569183633333-331-1-3------------       Sloan Kanaski
24161902132633331111--1--------------       Chhayank Warad
251910838163333---------------------       Noah Dohrmann
262010648163333---------------------       (anonymous user #214666)
27254273631-----------------------       Gary Nguyen
 
28 Rows(s) Affected
 
UTC 2024-12-3008:28:42
EST 2024-12-3003:28:42
Robert Cemper · Nov 21, 2024 go to post

Hi @Jeffrey Drumm ;
different approach: use your own datatype that always returns fixed MAXLEN string:

 

/// Make fixlength String according to MAXLEN parameterClass rcc.GetFix Extends%Library.String
{
/// Fill value <var>%val</var> to <a href="#MAXLEN">MAXLEN</a> characters.
Method Get() As%String [ CodeMode = generator, ServerOnly = 1 ]
{
	set code="$e(%val_"""_$j("",+%parameter("MAXLEN"))
	set code=code_""",1,"_+%parameter("MAXLEN")_")"$$$GENERATE( "  Quit "_code)
	QUIT$$$OK
}
}

and a test class:

Class rcc.FixTest Extends%RegisteredObject
{
Property test As rcc.GetFix(MAXLEN = 12);
}

and now some check from terminal:
 

SAMPLES>set z=##class(rcc.FixTest).%New() set z.test="rob"
SAMPLES>write z.test,$L(z.test)
rob         12

SAMPLES>;some oversized string
SAMPLES>set z.test=";some oversized string"
SAMPLES>write z.test,$L(z.test)
;some oversi12
SAMPLES>  

Hope this helps you along
 

Robert Cemper · Nov 11, 2024 go to post

#2)
Every LOCK persists until the process is ended or the LOCK is removed explicitely (LOCK -....)
it is not related to any error handling.

#1)
depends on your design.
If there is no conflict of subscripts between ADD and REMOVE possible there is no need of a Lock 

Robert Cemper · Nov 7, 2024 go to post

no need for this COPY
if your docker-compose.yml contains

    volumes:
      - ./:/home/irisowner/dev
 

Robert Cemper · Oct 27, 2024 go to post
  • .MAC  and much more .INT  are an almost 1:1 image of the runtime .OBJ code
  • they get implicitely compiled by ZSAVE command
  • while any .CLS gets first stored with a lot of internal parameters where XML is faster than UDL
  • then it's translated to .INT(at least) including all extra params,  
  • and inherited pieces and other features for comfort 
  • and then compiled as any other .INT for the final .OBJ 

So comparing .CLS  to .MAC/.INT is like comparing a goat to the final cheese you buy.

Robert Cemper · Oct 22, 2024 go to post
  • So you have a local instance of Caché as well.
  • Check with WRC if Cachè 13 is supported on Windows 11.
  • local access needs no firewall in Win 

     

Robert Cemper · Oct 21, 2024 go to post

A few questions:

  • my local IPv4 address in the ODBC connection
    • in ODBC you have to specify the IP address of the Caché server 
    • there you create the connection FROM YOUR local server
    • by default there's no connection outgoing from Caché
    • No need for your local IP - eventually for some firewalls
  • enabling remote access 
    • if you have username + PW from Caché you should have access
    • only some firewalls on server or client may block you
  • more important: what OS do you run on server and client ?    
  • and what type of connection do you try to establish ?  Web, SuperServer, Terminal, ... ?
Robert Cemper · Oct 21, 2024 go to post

To get the property position dynamically by program you may use this ClassMethod
 

ClassMethod PropSeq(classname As%String = "", propname As%String = "")
   As%String [ SqlProc ]
{
    if classname=""set classname=..%ClassName(1)
    set pos=0
    &sql(SELECT SequenceNumber INTO :pos 
        FROM %Dictionary.CompiledProperty
        WHERE transient=0ANDparent=:classname
        ANDname=:propname
    )
    if SQLCODE set pos="-1;"_SQLCODE
    quit pos
}
Robert Cemper · Oct 20, 2024 go to post

a somewhat 'dirty' approach

selectID, Name_GivenName from Demo.DemoPatient 
whereFORSOME %ELEMENT(Demo.DemoPatient.Aliases) ($LISTFIND(%value,'Twain')>0)

advantage - no need to know the structure of your serial class
risk - false positives for unexpected coincidences.  eg. Washington, John, ...

Robert Cemper · Oct 20, 2024 go to post

the example builds on the fact that the storage structure of the serial object is known

Storage Default{<Data name="serItemState"><Value name="1"><Value>Subject</Value></Value><Value name="2"><Value>Change</Value></Value><Value name="3">
<Value>Color</Value></Value></Data><State>serItemState</State><StreamLocation>^rcc.IC.serItemS</StreamLocation>

in this case color  is #3 in serial storage  ==>>  $list(%Value,3)

So you need to know the position of FamilyName in  HS.SDA3.Name (e.g.7 ?)
then you can use $list(%value,7) =  'Twain'   as condition

7 is just a guess as I don't have any HS* classes at hands 

Robert Cemper · Oct 8, 2024 go to post

BIG THANKS!
That soved the problem

It's a shame that the owner of the package didn't react to the ISSUE on Github or OEX for 3 months

Robert Cemper · Oct 2, 2024 go to post

run

USER > zn"%SYS"%SYS > ZLOAD JOURNAL
%SYS > Print

in WebTerminal you just get NOTHING
in normal terminal and iterm  you see the code  

Robert Cemper · Oct 2, 2024 go to post

@Mario Sanchez Macias  You missed the point.
The essential functionality is to have a total autonomous partition to work in.
It was never named so, but it is the real Shell for ObjectScript and its predecessors for >50 years !

Robert Cemper · Sep 26, 2024 go to post

simple case:
write some lines of ObjectScript in TERMINAL with Functions, ....
NO need to compile it, no INT, no MAC, no traces.
Just DO it:
---
or load some  INT., apply your changes, run it, forget it  
no save, no recompile, ...
WebTerminal is based on Xecute and compiled code
Same in Studio.
 

Robert Cemper · Sep 25, 2024 go to post

Overall a nice idea.
the package still needs some polishing to convince

suggestion1:  fix issue to build clean docker
suggestion2:  re-enable Start+Stop message so uses see it was moving
suggestion3:  show which class you check , kind of work log
suggestion4:  also step into sub-packages e.g. not just rcc but also rcc.unittests. codeinspector could be a good start
sugesstion5: allow also MAC, INT, INC code to be checked 

Robert Cemper · Sep 23, 2024 go to post

it would be great if the issues in building Docker container would be fixed.
so we can touch it and reduce frustration of evaluators first
Actually it is broken,  Issues pending since some days

Robert Cemper · Sep 23, 2024 go to post
  • is there anywhere a working example using the template ?
  • or a hint of how to apply it ?
Robert Cemper · Sep 18, 2024 go to post

Your code looks like a ClassQuery.   %Library.Query

This is not a Stored Procedure  :=>  a ClassMethod ...[SqlProc,SqlName=anyname]  

and everything happens inside this ClassMethod
you run is by CALL PROCEDURENAME