Database

Database and database acessors are most low-layer in the system.

Database design concept

Database table is designed by following rules.

Database accessors

Mostly, each database table has its accessor class.

Basically, database accessor should have minimal set of functions to get, update, insert and delete the data. More complex functions should be defined by Interface layer. But some complex functions which need to join several tables could be defined as a special case.

Usually, some of following functions are defined.

If some columns of a table requires to be multilingualized, two functions is implemented to take a value.

  1. One is for taking the value of one language. Function name is same to column name.
  2. Other is for taking the value of one language when the value is defined, otherwise one of other values of arbitrary language is taken. Function name has some_ as prefix.

Prev

Implementation Guideline

Top

Upward

Next

Interface