====== dbStore() ======
The ''dbStore()'' function stores a data object in the [[:en:create:databank]].
''void **dbStore**(string //key//, mixed //data object//)''
* //key//\\ The database key to be created, updated or deleted. The key must be between 2 and 63 characters long. Special characters (e.g., ä ö ü) may require more than one character.
* //data object//\\ This can be a single value or an indexed or associative array. Nested arrays are also possible.
Please note that objects that you store in the content database using ''dbStore()'' can only be read using ''[[:en:create:functions:dbretrieve]]'', not using ''[[:en:create:functions:dbget]]''.
==== Application example ====
The following PHP code would use the named array indices ''age'', ''gender'' and ''response'' to store two response values and all responses from the AB01 scale as an array.
$data = [
'age' => value('SD01_01'),
'gender' => value('SD02'),
'response' => valueList('AB01')
];
$person = caseSerial();
dbStore($person, $data);
The following object would then be stored in the database for content:
{
age: 19,
gender: 2,
response: {
AB01_01 => 3,
AB01_02 => 1,
AB01_03 => 2,
AB01_04 => 3
}
}