{"library":"sqlalchemy-pgspider","title":"SQLAlchemy PGSpider Dialect","type":"library","description":"SQLAlchemy-PGSpider is a Python library that provides a dialect for SQLAlchemy, enabling it to connect to PGSpider databases. As of version 0.1.0, it offers fundamental connectivity and query execution. It is a new project in active development, likely following a release cadence tied to upstream PGSpider and SQLAlchemy updates.","language":"python","status":"active","last_verified":"Fri Apr 17","install":{"commands":["pip install sqlalchemy-pgspider","pip install psycopg2-binary"],"cli":null},"imports":["from sqlalchemy import create_engine"],"auth":{"required":false,"env_vars":[]},"links":{"homepage":null,"github":"https://github.com/pgspider/sqlalchemy-pgspider","docs":null,"changelog":null,"pypi":"https://pypi.org/project/sqlalchemy-pgspider/","npm":null,"openapi_spec":null,"status_page":null,"smithery":null},"quickstart":{"code":"from sqlalchemy import create_engine, text\nimport os\n\n# Replace with your PGSpider connection details\n# For example: \"pgspider://user:password@host:port/database\"\nPGSPIDER_CONN_STR = os.environ.get('PGSPIDER_CONN_STR', 'pgspider://postgres:password@localhost:5432/pgspider_db')\n\ntry:\n    engine = create_engine(PGSPIDER_CONN_STR)\n\n    with engine.connect() as connection:\n        result = connection.execute(text(\"SELECT 1\"))\n        print(f\"PGSpider connection successful. Result: {result.scalar()}\")\n\nexcept Exception as e:\n    print(f\"Error connecting to PGSpider: {e}\")","lang":"python","description":"This quickstart demonstrates how to establish a connection to a PGSpider database using `create_engine` with the 'pgspider://' URI and execute a simple query. Ensure you have the `PGSPIDER_CONN_STR` environment variable set or update the placeholder directly.","tag":null,"tag_description":null,"last_tested":null,"results":[]},"compatibility":null}