Class Phalcon\Db\RawValue

This class allows to insert/update raw data without quoting or formating. The next example shows how to use the MySQL now() function as a field value.

  1. <?php
  2. $subscriber = new Subscribers();
  3. $subscriber->email = 'andres@phalconphp.com';
  4. $subscriber->createdAt = new \Phalcon\Db\RawValue('now()');
  5. $subscriber->save();

Methods

public getValue ()

Raw value without quoting or formating

public __toString ()

Raw value without quoting or formating

public __construct (unknown $value)

Phalcon\Db\RawValue constructor