A simple and light DB package
Project description
# instadb
A simple and light DB python package
### Installation
`pip install instadb`
### Basic Usage
```python
import instadb
db = instadb.Connection(url=database_url)
df = db.dataframe("select * from users limit 10")
```
If you have env variables that match the pattern `<key>_DATABASE_URL` then you can directly do:
```python
import instadb
df = instadb.key.dataframe("select * from users limit 10")
```
### Query from file
```python
df = instadb.key.dataframe(filename='./users.sql')
```
### Query from file with arguments
users.sql
```sql
select * from users where limit={limit}
```
```python
df = instadb.key.dataframe(filename='./users.sql', limit=100)
```
A simple and light DB python package
### Installation
`pip install instadb`
### Basic Usage
```python
import instadb
db = instadb.Connection(url=database_url)
df = db.dataframe("select * from users limit 10")
```
If you have env variables that match the pattern `<key>_DATABASE_URL` then you can directly do:
```python
import instadb
df = instadb.key.dataframe("select * from users limit 10")
```
### Query from file
```python
df = instadb.key.dataframe(filename='./users.sql')
```
### Query from file with arguments
users.sql
```sql
select * from users where limit={limit}
```
```python
df = instadb.key.dataframe(filename='./users.sql', limit=100)
```
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distributions
No source distribution files available for this release.See tutorial on generating distribution archives.
Built Distribution
Close
Hashes for instadb-0.4-py2.py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 13af064bda16941bdeff5c1e813a444b7341111b8a8939029cb336c528fcd57e |
|
MD5 | 6bf6ff4d69484f93e888ca63c8e8324e |
|
BLAKE2b-256 | a639681777e274979af0ce361f718ab645f6ea032c08e7d8e0da7db670efeb36 |