User bio
404 bio not found
Member since Jan 29, 2019
Replies:

If the System File Numbers in question are related to the database files themselves instead of the journal files, there's a query in SYS.Database called "CompactLocalList" that might get you what you need. Note: It seems that the query calls in SYS.Database need to be called from the %SYS namespace.

Try this (ugly, but hopefully useful) code snippet, and see if it gets you what you need:

zn "%sys"
set q = ##class(%SQL.Statement).%New()
set status = q.%PrepareClassQuery("SYS.Database","CompactLocalList")
set rset = q.%Execute()
while rset.%Next() { write !,rset.%Get("Directory"),*9,rset.%Get("SFN") }
w q.%Close()

Here's the documentation page for the SYS.Database class: https://docs.intersystems.com/irislatest/csp/documatic/%25CSP.Documatic.cls?LIBRARY=%25SYS&CLASSNAME=SYS.Database

and this will take you directoy to CompactLocalList.

There's one or two other calls that mention SFN's, so there might be other clues in the documentation referenced above.

Hope this helps!

I noticed that you're using Cache 2018.1. I'd like to just warn you that as of Cache 2017, this functionality was quite broken and InterSystems recommends you not use it. I don't know if it was fixed in 2018 or a later version, so I don't know for sure if your version is affected, but it's something you may want to be aware of.

If the functionality wasn't fixed in 2018, you can still recover the space in the database but it will have to be offline as no modifications to the database can happen during the process. There's a utility named ^GBLOCKCOPY that can copy all of the global database blocks from your existing database to a new one where the new database will only grow as large as necessary thereby reclaiming the free space.

See my answer to this post: https://community.intersystems.com/post/ensemble-2013-compacttruncate

And, here's more documentation regarding the ^GBLOCKCOPY utility: https://docs.intersystems.com/irislatest/csp/docbook/DocBook.UI.Page.cls?KEY=GSTU_remote_gblockcopy

Hope this helps!

With more recent versions, yes. The user didn't state what version Ensemble was in use, so I figured offering a solution that would work as far back as Ensemble 2009 wouldn't necessarily be a bad thing. I still have to support Ensemble 2012 and I did test the *-1 functionality there, and in that version this functionality did not yet exist. (Actually, a few sites I support are still using Cache 5.x. It may be geriatric, but it keeps on plugging along... :-) )

Certifications & Credly badges:
Roger has no Certifications & Credly badges yet.
Global Masters badges:
Followers:
Roger has no followers yet.
Following:
Roger has not followed anybody yet.