Spaces:
Paused
Paused
Download scratch/debug_db.py from 3SCError404/nexus: direct link, hf CLI and curl.
- Browser
- Download file 370 Bytes
-
https://huggingface.co/spaces/3SCError404/nexus/resolve/main/scratch/debug_db.py
- Command line
-
hf download hf://spaces/3SCError404/nexus/scratch/debug_db.py
-
curl -L -o debug_db.py https://huggingface.co/spaces/3SCError404/nexus/resolve/main/scratch/debug_db.py
370 Bytes
| import sqlite3 | |
| conn = sqlite3.connect('nexus.db') | |
| cursor = conn.execute("SELECT name FROM sqlite_master WHERE type='table'") | |
| tables = [r[0] for r in cursor.fetchall()] | |
| print(f"Tables: {tables}") | |
| for t in tables: | |
| cursor = conn.execute(f"PRAGMA table_info({t})") | |
| cols = [c[1] for c in cursor.fetchall()] | |
| print(f"Table {t} columns: {cols}") | |
| conn.close() | |