mirror of
https://github.com/EQEmu/Server.git
synced 2026-03-25 12:42:25 +00:00
Add MySQL Query logging at root
This commit is contained in:
parent
1928be9dd3
commit
1ad210ff29
@ -126,6 +126,8 @@ MySQLRequestResult DBcore::QueryDatabase(const char* query, uint32 querylen, boo
|
|||||||
|
|
||||||
MySQLRequestResult requestResult(res, (uint32)mysql_affected_rows(&mysql), rowCount, (uint32)mysql_field_count(&mysql), (uint32)mysql_insert_id(&mysql));
|
MySQLRequestResult requestResult(res, (uint32)mysql_affected_rows(&mysql), rowCount, (uint32)mysql_field_count(&mysql), (uint32)mysql_insert_id(&mysql));
|
||||||
|
|
||||||
|
Log.Out(Logs::General, Logs::MySQLQuery, "%s", query);
|
||||||
|
|
||||||
#if DEBUG_MYSQL_QUERIES >= 1
|
#if DEBUG_MYSQL_QUERIES >= 1
|
||||||
if (requestResult.Success())
|
if (requestResult.Success())
|
||||||
{
|
{
|
||||||
|
|||||||
@ -123,12 +123,12 @@ void EQEmuLogSys::ProcessLogWrite(uint16 log_category, std::string message)
|
|||||||
uint16 EQEmuLogSys::GetConsoleColorFromCategory(uint16 log_category){
|
uint16 EQEmuLogSys::GetConsoleColorFromCategory(uint16 log_category){
|
||||||
switch (log_category) {
|
switch (log_category) {
|
||||||
case Logs::Status:
|
case Logs::Status:
|
||||||
return Console::Color::Yellow;
|
|
||||||
case Logs::Normal:
|
case Logs::Normal:
|
||||||
return Console::Color::Yellow;
|
return Console::Color::Yellow;
|
||||||
case Logs::MySQLError:
|
case Logs::MySQLError:
|
||||||
case Logs::Error:
|
case Logs::Error:
|
||||||
return Console::Color::LightRed;
|
return Console::Color::LightRed;
|
||||||
|
case Logs::MySQLQuery:
|
||||||
case Logs::Debug:
|
case Logs::Debug:
|
||||||
return Console::Color::LightGreen;
|
return Console::Color::LightGreen;
|
||||||
case Logs::Quests:
|
case Logs::Quests:
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user