Skip to content

Instantly share code, notes, and snippets.

@asgrim
Created November 1, 2011 23:56
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save asgrim/1332315 to your computer and use it in GitHub Desktop.
Save asgrim/1332315 to your computer and use it in GitHub Desktop.
Excerpts from GD_Config::set
<?php
$bind = array(
'key' => $key,
'value' => $value,
);
$where['key = ?'] = $key;
$db = Zend_Db_Table::getDefaultAdapter()
$db->update('configuration', $bind, $where);
// Zend_Db_Statement_Exception: SQLSTATE[42000]: Syntax error or access violation: 1064 You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'key = 'last_page_load')'
// I tried it with only this too:
$bind = array(
'value' => $value,
);
@asgrim
Copy link
Author

asgrim commented Nov 1, 2011

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment