Raised This Month: $ Target: $400

MySQL: Invalid database Handle

Post New Thread Reply   
Thread Tools Display Modes
Author Message
Junior Member
Join Date: Aug 2016
Old 11-01-2016 , 06: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 and the credentials are also valid. Any ideas?

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

if (hDatabase == null)
    // do something
Neuro Toxin is offline

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 13:19.

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