User bio
404 bio not found
Member since Jun 6, 2022

To elaborate:

1) I wanted to use the object interface because it handles multi table inserts when my %Persistent object has properties that are also %Persistent. 

2) I wanted to prevent indices from being updated on %Save so that my bulk inserts would be faster. I can then defer the building of my indices after my bulk insert is done. I was aware of %NOINDEX but because of point 1) I was hoping to take an oop approach. 

For small globals where MB is too coarse a unit of measurement, do you think it would be worthwhile to calculate the size of a global based on the number of blocks allocated for it, then multiply that number by the blocksize? 

For example,

Do ##class(%GlobalEdit).GetGlobalSizeBySubscript(globalDirectory, globalName, "", .size) 
set numBlocks = Size("Blocks","Total")
set blockSizeForDB = ##class(%GlobalEdit).Open(globalName, globalDirectory).DatabaseBlockSize
set globalSize = numBlocks * blockSizeForDB
write "Size for global """, globalName, """ in kilobytes: ", globalSize, !
Certifications & Credly badges:
Michael has no Certifications & Credly badges yet.
Global Masters badges:
Michael has no Global Masters badges yet.
Michael has no followers yet.
Michael has not followed anybody yet.