Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

.NET 5.0 | Implement SqlException.SqlState #648

Open
roji opened this issue Jul 12, 2020 · 3 comments
Open

.NET 5.0 | Implement SqlException.SqlState #648

roji opened this issue Jul 12, 2020 · 3 comments
Labels
💡 Enhancement Issues that are feature requests for the drivers we maintain.

Comments

@roji
Copy link
Member

roji commented Jul 12, 2020

dotnet/runtime#35601 introduces DbException.SqlState for .NET 5.0, for standard 5-character error codes.

SQL Server has its own incompatible numeric error code scheme, currently surfaced via SqlError.Number. However, the SQL Server ODBC driver apparently maps the native SQL Server errors to SQLSTATE values. As pointed out by @cheenamalhotra, the JDBC driver does the same, although it maps only a handful of codes (maybe the ODBC translation could be copied?)

@roji roji added the 💡 Enhancement Issues that are feature requests for the drivers we maintain. label Jul 12, 2020
@cheenamalhotra
Copy link
Member

Thanks @roji

Acknowledged for .NET 5.0 new APIs.

@asante07
Copy link

10:14:55 AM [main] Initializing Control Panel
10:14:55 AM [main] Windows Version: Enterprise 64-bit
10:14:55 AM [main] XAMPP Version: 8.2.4
10:14:55 AM [main] Control Panel Version: 3.3.0 [ Compiled: Apr 6th 2021 ]
10:14:55 AM [main] You are not running with administrator rights! This will work for
10:14:55 AM [main] most application stuff but whenever you do something with services
10:14:55 AM [main] there will be a security dialogue or things will break! So think
10:14:55 AM [main] about running this application with administrator rights!
10:14:55 AM [main] XAMPP Installation Directory: "c:\xampp"
10:14:55 AM [main] Checking for prerequisites
10:15:29 AM [main] All prerequisites found
10:15:29 AM [main] Initializing Modules
10:15:29 AM [main] Starting Check-Timer
10:15:29 AM [main] Control Panel Ready
10:15:45 AM [mysql] Attempting to start MySQL app...
10:15:47 AM [mysql] Status change detected: running
10:15:52 AM [mysql] Status change detected: stopped
10:15:52 AM [mysql] Error: MySQL shutdown unexpectedly.
10:15:52 AM [mysql] This may be due to a blocked port, missing dependencies,
10:15:52 AM [mysql] improper privileges, a crash, or a shutdown by another method.
10:15:52 AM [mysql] Press the Logs button to view error logs and check
10:15:52 AM [mysql] the Windows Event Viewer for more clues
10:15:52 AM [mysql] If you need more help, copy and post this
10:15:52 AM [mysql] entire log window on the forums
10:16:33 AM [Apache] Attempting to start Apache app...
10:16:34 AM [Apache] Status change detected: running

Is there a way of finding out MySql Server error if the MySQL shutdown unexpectedly. I tried looking at event logs but don't understand how to fix the error. Very new to MySQL. Similar to implementation of SqlState!!? Thanks in advance.

@ErikEJ
Copy link
Contributor

ErikEJ commented Jun 23, 2023

@asante07 I think you are asking in the wrong place...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
💡 Enhancement Issues that are feature requests for the drivers we maintain.
Projects
None yet
Development

No branches or pull requests

4 participants