Инструменты пользователя

Инструменты сайта


limb3:en:architecture:lmbsql_field_criteria

lmbSQLFieldCriteria

lmbSQLFieldCriteria creates a simple condition for a db table field.

lmbSQLFieldCriteria accepts field name, value and condition type in constructor:

$criteria = new lmbSQLFieldCriteria('contract.start_date', $date_str, lmbSQLFieldCriteria:: LESS);
$criteria = new lmbSQLFieldCriteria('contract.end_date', $date_str, '>');

Here is the list of available condition types:

  • EQUAL = «=»;
  • NOT_EQUAL = «<>»;
  • GREATER = «>»;
  • LESS = « < »;
  • GREATER_EQUAL = « >= »;
  • LESS_EQUAL = « ⇐ »;
  • LIKE = « LIKE »;
  • NOT_LIKE = « NOT LIKE »;
  • IN = « IN »;
  • NOT_IN = « NOT IN »;
  • ISNULL = « IS NULL»;
  • ISNOTNULL = « IS NOT NULL»;

Обсуждение

Ваш комментарий. Вики-синтаксис разрешён:
   ____  __  __  ____    __ __   __ 
  / __/ / / / / / __ \  / // /  / / 
 _\ \  / /_/ / / /_/ / / _  /  / /__
/___/  \____/  \___\_\/_//_/  /____/
 
limb3/en/architecture/lmbsql_field_criteria.txt · Последние изменения: 2010/11/10 10:02 (внешнее изменение)