https://github.com/veeeetzzzz/langchain-sql-db-examples
https://github.com/veeeetzzzz/langchain-sql-db-examples
database mysql postgresql sql
Last synced: 3 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/veeeetzzzz/langchain-sql-db-examples
- Owner: Veeeetzzzz
- Created: 2023-05-01T11:40:30.000Z (about 3 years ago)
- Default Branch: main
- Last Pushed: 2023-05-05T20:19:56.000Z (about 3 years ago)
- Last Synced: 2026-02-28T20:14:40.333Z (4 months ago)
- Topics: database, mysql, postgresql, sql
- Language: Python
- Homepage:
- Size: 10.7 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Langchain SQL database examples
Examples of how to use Langchain to connect to mySQL/PostgreSQL databases - use these to interact with your database & load data.
This Python script connects to a mySQL/PostgreSQL database and imports a specified table. Error messages will confirm once you connect to database and how many rows it was able to select from the table.
# Usage
These will all be in Python - so download the script you want to use, update the file with your DB type and connection information and then navigate to the directory it's stored in via CMD/PowerShell/Terminal and run:
`python connect.py`
Output should look like this:
