Use CompileFormulaContext in CompileDBFormula() and CalcAfterLoad().

Also make some adjustment in order to handle formula cell's "temp grammar"
correctly.

Change-Id: I6fdd5c67bb95e4de90ea71db624c9610c1e2febf