I just looked at the source dir for openacs.org site but I'm a bit perplexed:
[janines@samoyed packages]$ find . -type f -exec fgrep -l last_child_post {} \;
./forums/www/forum-view-postgresql.xql
./forums/www/forum-view.adp
Where is the code that sets the value of last_child_post? Both of these files just query it.