-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

$aUpdateData = array('expiration' => new
Zend_Db_Expr('DATE_ADD(IF(expiration IS NOT NULL,
> expiration ,now()),INTERVAL 1 MONTH)'));

BornForCode schrieb:
> Hello
> 
> How can i make an update that has following Sql:
> UPDATE app_user SET expiration = DATE_ADD(IF(expiration IS NOT NULL,
> expiration ,now()),INTERVAL 1 MONTH) WHERE id =13
> 
> Because the ordinary update method is not working :(:
> 
> $aUpdateData = array('expiration' => 'DATE_ADD(IF(expiration IS NOT NULL,
> expiration ,now()),INTERVAL 1 MONTH)');
>                                               $Affected = 
> $oUser->update($aUpdateData, 'id =
> '.$this->_getParam('user_id'));

- --
...................................
:  ___   _   ___ ___ ___ _ ___    :
: |   \ /_\ / __| _ \ _ (_)   \   :
: | |) / _ \\__ \  _/   / | |) |  :
: |___/_/:\_\___/_| |_|_\_|___/   :
:........:........................:
: Web    : http://www.dasprids.de :
: E-mail : [EMAIL PROTECTED]       :
: Jabber : [EMAIL PROTECTED]     :
: ICQ    : 105677955              :
:........:........................:
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFIHfVB0HfT5Ws789ARAjvRAJ9L8o+enHCBTKMOXQ7wREZee1l7twCeI9MW
RHwZHJ/jNLcXjk/eeX8vd4A=
=8lrk
-----END PGP SIGNATURE-----

Reply via email to