Skip to content

Commit 77238a1

Browse files
authored
Readme file update (#69)
This pull request updates the `README.md` file to reflect new compatibility, platform support, and feature enhancements for the `mssql-python` driver. The changes aim to improve clarity and provide updated information for users. ### Compatibility and platform updates: * Added compatibility information stating that the driver supports Python versions >= 3.10. * Updated supported platforms to include MacOS alongside Windows, with Linux support still forthcoming. ### Feature enhancements: * Introduced a new section on connection pooling, highlighting built-in support for reusing active database connections for better performance and scalability. ### Project status update: * Changed the project status from "alpha phase" to "Public Preview," indicating progress toward General Availability (GA). --------- Co-authored-by: Jahnvi Thakkar <jathakkar@microsoft.com>
1 parent fcdc967 commit 77238a1

File tree

1 file changed

+44
-38
lines changed

1 file changed

+44
-38
lines changed

README.md

Lines changed: 44 additions & 38 deletions
Original file line numberDiff line numberDiff line change
@@ -1,100 +1,106 @@
11
# Microsoft Python Driver for SQL Server
2-
2+
33
**mssql-python** is a Python driver for Microsoft SQL Server and the Azure SQL family of databases. It leverages Direct Database Connectivity (DDBC) that enables direct connections to SQL Server without requiring an external driver manager. Designed to comply with the [DB API 2.0](https://peps.python.org/pep-0249/) specification, this driver also introduces Pythonic enhancements for improved usability and functionality. It supports a full range of database operations, including connection management, query execution, and transaction handling.
4-
4+
5+
The driver is compatible with all the Python versions >= 3.10
6+
57
[Documentation](https://github.com/microsoft/mssql-python/wiki) | [Release Notes](https://github.com/microsoft/mssql-python/releases) | [Roadmap](https://github.com/microsoft/mssql-python/blob/main/ROADMAP.md)
6-
8+
79
> **Note:**
8-
> This project is currently in an alpha phase, meaning it is still under active development. We are looking to validate core functionalities and gather initial feedback before a broader public launch. Please use with caution and avoid production environments.
10+
> This project is currently in Public Preview, meaning it is still under active development. We are working on core functionalities and gathering more feedback before GA. Please use with caution and avoid production environments.
911
>
1012
## Installation
11-
13+
1214
mssql-python can be installed with [pip](http://pypi.python.org/pypi/pip)
1315
```bash
1416
pip install mssql-python
1517
```
1618
## Key Features
17-
### Supported Platforms
18-
19-
Windows
20-
19+
### Supported Platforms
20+
21+
Windows and MacOS
22+
2123
> **Note:**
22-
> Support for macOS and Linux is coming soon
23-
>
24-
24+
> Support for Linux is coming soon
25+
>
26+
2527
### DBAPI v2.0 Compliance
26-
28+
2729
The Microsoft **mssql-python** module is designed to be fully compliant with the DB API 2.0 specification. This ensures that the driver adheres to a standardized interface for database access in Python, providing consistency and reliability across different database systems. Key aspects of DBAPI v2.0 compliance include:
28-
30+
2931
- **Connection Objects**: Establishing and managing connections to the database.
3032
- **Cursor Objects**: Executing SQL commands and retrieving results.
3133
- **Transaction Management**: Supporting commit and rollback operations to ensure data integrity.
3234
- **Error Handling**: Providing a consistent set of exceptions for handling database errors.
3335
- **Parameter Substitution**: Allowing the use of placeholders in SQL queries to prevent SQL injection attacks.
34-
36+
3537
By adhering to the DB API 2.0 specification, the mssql-python module ensures compatibility with a wide range of Python applications and frameworks, making it a versatile choice for developers working with Microsoft SQL Server, Azure SQL Database, and Azure SQL Managed Instance.
36-
38+
3739
### Support for Microsoft Entra ID Authentication
38-
40+
3941
The Microsoft mssql-python driver enables Python applications to connect to Microsoft SQL Server, Azure SQL Database, or Azure SQL Managed Instance using Microsoft Entra ID identities. It supports various authentication methods, including username and password, Microsoft Entra managed identity, and Integrated Windows Authentication in a federated, domain-joined environment. Additionally, the driver supports Microsoft Entra interactive authentication and Microsoft Entra managed identity authentication for both system-assigned and user-assigned managed identities.
40-
42+
4143
### Enhanced Pythonic Features
42-
44+
4345
The driver offers a suite of Pythonic enhancements that streamline database interactions, making it easier for developers to execute queries, manage connections, and handle data more efficiently.
44-
46+
47+
### Connection Pooling
48+
49+
The Microsoft mssql_python driver provides built-in support for connection pooling, which helps improve performance and scalability by reusing active database connections instead of creating a new connection for every request.
50+
51+
4552
## Getting Started Examples
46-
4753
Connect to SQL Server and execute a simple query:
48-
54+
4955
```python
5056
import mssql_python
51-
57+
5258
# Establish a connection
5359
# Specify connection string
5460
connection_string = "SERVER=<your_server_name>;DATABASE=<your_database_name>;UID=<your_user_name>;PWD=<your_password>;Encrypt=yes;"
5561
connection = mssql_python.connect(connection_string)
56-
62+
5763
# Execute a query
5864
cursor = connection.cursor()
5965
cursor.execute("SELECT * from customer")
6066
rows = cursor.fetchall()
61-
67+
6268
for row in rows:
6369
print(row)
64-
70+
6571
# Close the connection
6672
connection.close()
67-
73+
6874
```
69-
75+
7076
## Still have questions?
71-
77+
7278
Check out our [FAQ](https://github.com/microsoft/mssql-python/wiki/Frequently-Asked-Questions). Still not answered? Create an [issue](https://github.com/microsoft/mssql-python/issues/new/choose) to ask a question.
73-
79+
7480
## Contributing
75-
81+
7682
This project welcomes contributions and suggestions. Most contributions require you to agree to a
7783
Contributor License Agreement (CLA) declaring that you have the right to, and actually do, grant us
7884
the rights to use your contribution. For details, visit https://cla.opensource.microsoft.com.
79-
85+
8086
When you submit a pull request, a CLA bot will automatically determine whether you need to provide
8187
a CLA and decorate the PR appropriately (e.g., status check, comment). Simply follow the instructions
8288
provided by the bot. You will only need to do this once across all repos using our CLA.
83-
89+
8490
This project has adopted the [Microsoft Open Source Code of Conduct](https://opensource.microsoft.com/codeofconduct/).
8591
For more information see the [Code of Conduct FAQ](https://opensource.microsoft.com/codeofconduct/faq/) or
8692
contact [opencode@microsoft.com](mailto:opencode@microsoft.com) with any additional questions or comments.
87-
93+
8894
## License
8995
The mssql-python driver for SQL Server is licensed under the MIT license, except the dynamic-link libraries (DLLs) in the [libs](https://github.com/microsoft/mssql-python/tree/alphaChanges/mssql_python/libs) folder
9096
that are licensed under MICROSOFT SOFTWARE LICENSE TERMS.
91-
97+
9298
Please review the [LICENSE](LICENSE) file for more details.
93-
99+
94100
## Trademarks
95-
101+
96102
This project may contain trademarks or logos for projects, products, or services. Authorized use of Microsoft
97103
trademarks or logos is subject to and must follow
98104
[Microsoft's Trademark & Brand Guidelines](https://www.microsoft.com/en-us/legal/intellectualproperty/trademarks/usage/general).
99105
Use of Microsoft trademarks or logos in modified versions of this project must not cause confusion or imply Microsoft sponsorship.
100-
Any use of third-party trademarks or logos are subject to those third-party's policies.
106+
Any use of third-party trademarks or logos are subject to those third-party's policies.

0 commit comments

Comments
 (0)