Repository navigation
MySQL_GetConnectionError
imshooter edited this page Oct 24, 2026
·
1 revision
The message of the last time the handle failed to connect.
native bool:MySQL_GetConnectionError(MySQL:handle, error[], size = sizeof (error));| Parameter | Description | Default |
|---|---|---|
MySQL:handle |
Handle to check. | |
error[] |
Array for the message. | |
size |
Size of the array. | sizeof (error) |
-
truewhen the message was written. -
falsewhen the handle does not exist.
stock ReportConnection(MySQL:handle) {
new
error[128]
;
if (MySQL_IsConnected(handle)) {
print("Connected.");
return;
}
MySQL_GetConnectionError(handle, error);
printf("Not connected, error %i: %s", MySQL_GetConnectionErrno(handle), error);
}- MySQL_GetConnectionErrno: The error of the last time the handle failed to connect.
- MySQL_IsConnected: Whether the connection of the ordered queries is open.
MySQL 0.2.0 · Repository · Releases · MIT License
Guides
- Installation
- Configuration
- Queries
- Results
- JSON cells
- Prepared statements
- Passwords
- Errors
- TLS
- Coming from R41
- Performance
Reference
Functions