->get()

->get() --  Simple Get (Select) request

Synopsis

int $DB_DataObject->get (mixed Key or Value [, mixed value])

Описание

Get a result using key, value. Returns Number of rows located (usually 1) for success, and puts all the table columns into this classes variables. If only one parameter is used, it is assumed that first parameter is a value and get() will use the primary key.

Параметр

Возвращаемое значение

int - Number of rows

Throws

Таблица 34-1. Возможные значения PEAR_Error

Error codeError messageMeaningSolution
DB_DATAOBJECT_ERROR_INVALIDCONFIG"No Keys available for $table"  
DB_DATAOBJECT_ERROR_INVALIDARGS"No Value specified for get"  

Заметка

Эта функция не должна вызываться статически.

You should avoid calling get on the same object instance twice, as this will result in unexpected results.

Пример


HIVE: All information for read only. Please respect copyright!
Hosted by hive йца: йХЕБЯЙЮЪ ЦНПНДЯЙЮЪ АХАКХНРЕЙЮ