I am trying to update the database with the original column's value plus (+1) or minus (-1)
$column_name = 'mycolumnname';
$table_name - 'mytablename';
$db = JFactory::getDbo();
$query = $db->getQuery(true);
$fields = array($db->quoteName($column_name) . ' = ' . $db->quote($column_name +1));
$query->update($db->quoteName($table_name))->set($fields);
$db->setQuery($query);
$result = $db->execute();
If i run this it will always set the column value to 1. What am i doing wrong?