set blocksize to 0 create table employee ( id i, notes m ) insert into employee values ( 1, "" ) SELECT * FROM employee INTO CURSOR xxEmployee readwrite select xxEmployee ? "starting must bloat it" set step on FOR ix = 1 TO 1000 replace notes WITH REPLICATE('X',ix * 1000) in xxEmployee ENDFOR ? len( xxEmployee.notes ) set step on ? "starting won't bloat it phase" FOR ix = 1 TO 1000 replace notes WITH REPLICATE('X',(1000-ix) * 1000) in xxEmployee ENDFOR ? len( xxEmployee.notes )at the midpoint of execution I have a 409,152kb file in my temp folder. the whole second half of the code execution does not increase the size one iota.
set blocksize to 0 create table employee ( id i, notes m ) insert into employee values ( 1, "" ) SELECT * FROM employee INTO CURSOR xxEmployee readwrite FOR ix = 1 TO 1000 replace notes WITH REPLICATE('X',INT(RAND()*1000000)) ENDFORThe tmp file is sitting at 254,565 mb showing that indeed some memo reuse occurred with the tmp file slightly larger that 1/2 of the one from my code above.
>SELECT * FROM employee INTO CURSOR xxEmployee readwrite >start = SECONDS() >FOR ix = 1 TO 1000 >replace notes WITH REPLICATE('X',INT(RAND()*1000000)) >ENDFOR >? SECONDS()-m.start >Keep an eye in task manager and temp folder. You'd see memo file going sky high (F5 at least once or you wouldn't).
>SELECT * FROM employee INTO CURSOR xxEmployee readwrite >SCATTER NAME oRec memo >start = SECONDS() >FOR ix = 1 TO 1000 >oRec.Notes = REPLICATE('X',INT(RAND()*1000000)) >ENDFOR >? SECONDS()-m.start >Again checking in task manager.