As a simple example, suppose I want to make a grid of mathematical products:
A | B | C
----------
7 | 2 | 14
1 | 5 | 5
2 | 4 | 8
6 | 0 | 0
3 | 3 | 9
...
Suppose my database only stores values for A and B. I then have 3 options:
- Calculate C server-side, and use ExtJS models with A, B, C as fields
- Calculate C client-side when initialing loading a record (via some reader?) HOW TO DO THIS
- Calculate C client-side, after the grid has rendered, by going row-by-row, extracting A and B and setting the value of C
- Just store A, B, C in the database
Thoughts? I don't know why, but I think (2) is the cleanest if I can find a way of doing it..