Fatal Error in PHP.trigger_error();

Expression #1 of ORDER BY clause is not in GROUP BY clause and contains nonaggregated column 'dt_vanilla_usergroup.c.DateInserted' which is not functionally dependent on columns in GROUP BY clause; this is incompatible with sql_mode=only_full_group_by

The error occurred on or near: /home/marketing001/public_html/community/library/database/class.database.php

418:                     $this->closeConnection();
419:                     continue;
420:                 }
421: 
422:                 trigger_error($message, E_USER_ERROR);
423:             }
424: 
425:         }
426: 

Backtrace:

/home/marketing001/public_html/community/library/database/class.database.phpPHP::Gdn_ErrorHandler();
[/home/marketing001/public_html/community/library/database/class.database.php:422] PHP::trigger_error();
[/home/marketing001/public_html/community/library/database/class.sqldriver.php:1663] Gdn_Database->query();
[/home/marketing001/public_html/community/library/database/class.sqldriver.php:614] Gdn_SQLDriver->query();
[/home/marketing001/public_html/community/plugins/VanillaInThisDiscussion/class.inthisdiscussionmodule.php:46] Gdn_SQLDriver->get();
[/home/marketing001/public_html/community/plugins/VanillaInThisDiscussion/default.php:61] InThisDiscussionModule->getData();
[/home/marketing001/public_html/community/library/core/class.pluginmanager.php:867] VanillaInThisDiscussionPlugin->discussionController_beforeDiscussionRender_handler();
[/home/marketing001/public_html/community/library/core/class.pluginmanager.php:775] Gdn_PluginManager->callEventHandler();
[/home/marketing001/public_html/community/library/core/class.pluggable.php:133] Gdn_PluginManager->callEventHandlers();
[/home/marketing001/public_html/community/applications/vanilla/controllers/class.discussioncontroller.php:251] Gdn_Pluggable->fireEvent();
[/home/marketing001/public_html/community/library/core/class.dispatcher.php:329] DiscussionController->index();
[/home/marketing001/public_html/community/index.php:44] Gdn_Dispatcher->dispatch();

Variables in local scope:

[Sql] 'select u.UserID as `UserID`, u.Name as `Name`, u.Photo as `Photo`, max(c.DateInserted) as `DateLastActive`
from GDN_User u
join GDN_Comment c on u.UserID = c.InsertUserID
where c.DiscussionID = :cDiscussionID
group by u.UserID, u.Name
order by c.DateInserted desc
limit 20'
[InputParameters] array (
  ':cDiscussionID' => 1,
)
[Options] array (
  'Type' => 'select',
  'Slave' => NULL,
  'ReturnType' => 'DataSet',
)
[ReturnType] 'DataSet'
[tries] 2
[try] 0
[PDO] array (
)
[PDOStatement] false
[state] '42000'
[code] 1055
[message] 'Expression #1 of ORDER BY clause is not in GROUP BY clause and contains nonaggregated column \'dt_vanilla_usergroup.c.DateInserted\' which is not functionally dependent on columns in GROUP BY clause; this is incompatible with sql_mode=only_full_group_by'
[ex] array (
)

Need Help?

If you are a user of this website, you can report this message to a website administrator.

If you are an administrator of this website, you can get help at the Vanilla Community Forums.

Additional information for support personnel: