- Newest
- Most votes
- Most comments
When setting up JDBC connections in AWS Glue to SQL Server databases with special characters in their names or to named instances, you need to adjust your connection string format to handle these cases correctly.
For databases with special characters like hyphens: You should enclose the database name in square brackets. For example, instead of using: jdbc:sqlserver://10.10.10.10:1433;databaseName=database-name
Use: jdbc:sqlserver://10.10.10.10:1433;databaseName=[database-name]
For connecting to named instances: When connecting to a named instance, you need to use a slightly different format. Instead of using a backslash () to separate the server name and instance name, use a backslash and then another backslash (\). For example:
jdbc:sqlserver://10.10.10.10\instancename:1433;databaseName=yourdatabase
If you're combining both scenarios (named instance and database with special characters): jdbc:sqlserver://10.10.10.10\instancename:1433;databaseName=[database-name]
Remember to ensure that your security groups, network settings, and IAM permissions are correctly configured to allow the connection. Also, make sure you're using a compatible JDBC driver version for your SQL Server version.
If you continue to experience issues, you may want to review the CloudWatch logs for your Glue job for more detailed error messages or consider using the AWS Systems Manager AWSSupport-TroubleshootGlueConnection runbook to help identify and resolve common connection issues.
Sources
AWS Glue Connection to RDS SQL Server Fails – "Failed status due to failed connection" | AWS re:Post
Troublehsoot AWS Glue connection to a JDBC data source | AWS re:Post
JDBC connections - AWS Glue
answered 2 years ago
Relevant content
asked 2 years ago
- AWS OFFICIALUpdated 2 years ago

The double backslash between the server name and instance name does not work.