semvec/pypi-packages huggingface dataset:
sqlalchemy-lightening 0.6.0
making SQLAlchemy great again
License: MIT

SQLAlchemy Lightening
===
Making SQLAlchemy great again


#### Install
```bash
pip install sqlalchemy_ligthening
```


#### Usage
```python
# load by id
Person.get(1)

# load multiple by id
Person.get([1, 2, 3])

# basic filter
Person.where(name='dpepper')

# where `name` in ...
Person.where(name=['dpepper', 'thatguy'])

# mix and match
Person.where(Person.id != 1, name='dpepper')

# standard utilities
Person.all
Person.first

# standard SQLAlchemy query
Person.query
```


##  Example Setup
```python
from sqlalchemy import create_engine
from sqlalchemy.ext.declarative import declarative_base
from sqlalchemy.orm import sessionmaker
from sqlalchemy_lightening import LighteningBase


# create base sqlalchemy model
Base = declarative_base()

# extend LighteningBase mixin
class Person(LighteningBase, Base):
    id = Column(Integer, primary_key=True)
    name = Column(String(250))

engine = create_engine('sqlite:///:memory:')
session = sessionmaker(bind=engine)()

Base.metadata.create_all(engine)
Base.metadata.bind = engine

# wire things up
LighteningBase.query_class = session.query

# good to go
Person.winning
```


----
[![installs](https://img.shields.io/pypi/dm/sqlalchemy_lightening.svg?label=installs)](https://pypi.org/project/sqlalchemy_lightening)
lotterycn 0.0.4
LotteryCN is a library which aims to bring enjoyable analysis of lottery in Python
License: MIT
Requires Python: >=3.6
Keywords: lottery

<p align="center">
  <img src="https://github.com/UlionTse/lotterycn/blob/main/docs/lotterycn_logo.png"/>
</p>
<p align="center">
  <a href="https://pypi.org/project/lotterycn"><img alt="PyPI - Version" src="https://img.shields.io/pypi/v/lotterycn.svg"></a>
  <a href="https://anaconda.org/conda-forge/lotterycn"><img alt="Conda - Version" src="https://img.shields.io/conda/vn/conda-forge/lotterycn.svg"></a>
  <a href="https://pypi.org/project/lotterycn"><img alt="PyPI - License" src="https://img.shields.io/pypi/l/lotterycn.svg"></a>
  <a href="https://pypi.org/project/lotterycn"><img alt="PyPI - Python" src="https://img.shields.io/pypi/pyversions/lotterycn.svg"></a>
  <a href="https://pypi.org/project/lotterycn"><img alt="PyPI - Status" src="https://img.shields.io/pypi/status/lotterycn.svg"></a>
  <a href="https://pypi.org/project/lotterycn"><img alt="PyPI - Wheel" src="https://img.shields.io/badge/wheel-yes-brightgreen.svg"></a>
  <a href="https://pypi.org/project/lotterycn"><img alt="Downloads" src="https://pepy.tech/badge/lotterycn"></a>
</p>

* * *

**LotteryCN** is a library which aims to bring **enjoyable** analysis of lottery in Python.

- [Installation](#installation)
  - [From PyPI](#from-PyPI)
  - [From Conda](#from-Conda)
- [License](#License)

## Installation

### From PyPI

```shell
pip install --upgrde lotterycn
```

### From Conda

```shell
conda install -c conda-forge lotterycn
```