Solved

How to use SQLAlchemy 2.0 library with CData Python connector.

  • 25 October 2023
  • 1 reply
  • 46 views

Userlevel 1
Badge

When using the Python connector in conjunction with SQLAlchemy, we introduced a new dialect with the "_2" suffix to accommodate SQLAlchemy 2.0. For instance, the QB Python connector features a dialect named "quickbooks_2."

Previously, we utilized automap_base in the following manner:

engine = create_engine("quickbooks:///?<connection string>")

However, if the customer wishes to employ SQLAlchemy 2.0 and prevent potential errors when using automap_base, the following code should be used:

engine = create_engine("quickbooks_2:///?<connection string>")

icon

Best answer by Ankit Singh 25 October 2023, 17:48

View original

1 reply

Userlevel 5
Badge +1

Thanks for sharing, @Venu!

Reply