Raised This Month: $53 Target: $400
 13% 

MySQL: Invalid database Handle


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
aequabit
Junior Member
Join Date: Aug 2016
Old 11-01-2016 , 05:17   MySQL: Invalid database Handle
Reply With Quote #1

On Windows everything works fine, but on Linux I get the following error when calling SQL_TQuery:

HTML Code:
L 11/01/2016 - 10:14:41: [SM] Exception reported: Invalid database Handle 0 (error: 4)
L 11/01/2016 - 10:14:41: [SM] Blaming: mycoolplugin.smx
L 11/01/2016 - 10:14:41: [SM] Call stack trace:
L 11/01/2016 - 10:14:41: [SM]   [0] SQL_TQuery
L 11/01/2016 - 10:14:41: [SM]   [1] Line 18, D:\sourcemod\scripting\mycoolplugin.sp::OnPluginStart
The MySQL server is running on 127.0.0.1 and the credentials are also valid. Any ideas?

Last edited by aequabit; 11-01-2016 at 05:18.
aequabit is offline
Neuro Toxin
Veteran Member
Join Date: Oct 2013
Location: { closing the void; }
Old 11-01-2016 , 07:02   Re: MySQL: Invalid database Handle
Reply With Quote #2

Code:
if (hDatabase == null)
{
    // do something
    return;
}
__________________
Neuro Toxin is offline
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 15:25.


Powered by vBulletin®
Copyright ©2000 - 2021, vBulletin Solutions, Inc.
Theme made by Freecode