Se você gostou do que viu, por favor apoie esta ferramenta no Developer Tools 2025 contest. A votação se encerra à meia-noite (EDT) no domingo, dia 3.
Validate Global Indexes and Rebuild them
Hello, how are you?
First of all thanks for your time reading this question.
We are investigating how to validate the indexes of a global. We have read:
https://docs.intersystems.com/irisforhealth20251/csp/docbook/DocBook.UI....
And:
https://docs.intersystems.com/irisforhealth20251/csp/documatic/%25CSP.Do...
We want to validate the inxedes of the global titled "Ens.Util.LogD". We have executed on the ObjectScript terminal, on the desired namespace:
ESBSSCC>set tSC = $SYSTEM.OBJ.ValidateIndices("Ens.Util.LogD","",0,1,0,1,.errors)
Being the output:
ESBSSCC>zw tSC
tSC="0 "_$lb($lb(5002,"<UNDEFINED>loadtab+2^%ocsCacheSQLFiler0 ^oddEXTR(""Ens.Util.LogD"",91)",,,,,,,,$lb(,"ESBSSCC",$lb("^loadtab+2^%ocsCacheSQLFiler0^1","d^opentab+3^%ocsCacheSQLFiler0^2","e^filer+5^%ocsCacheSQLFiler^2","d^ValidateIndices+4^%SYS.SECURITY^1","e^zValidateIndices+12^%SYSTEM.OBJ.1^1","e^^^0"))))/* ERROR #5002: Error de cache: <UNDEFINED>loadtab+2^%ocsCacheSQLFiler0 ^oddEXTR("Ens.Util.LogD",91) */
In addition we have read:
https://docs.intersystems.com/irisforhealth20251/csp/docbook/DocBook.UI....
Because of the previous error, we have thought that rebuilding its indexes was needed, so we executed:
ESBSSCC>do ##class(Ens.Util.LogD).BuildIndex()
It says:
DO ##CLASS(Ens.Util.LogD).BuildIndex()
^
<CLASS DOES NOT EXIST> *Ens.Util.LogD
Then we tried:
ESBSSCC>do ##class(Ens.Util.Log).BuildIndex()
It outputs:
DO ##CLASS(Ens.Util.Log).BuildIndex()
^
<METHOD DOES NOT EXIST> *BuildIndex,Ens.Util.Log
What are we doing wrong?
How could we validate the index of the Global?
When do we need to rebuild its indexes?
Thank you so much for your help!