tina - Elasticsearch 的 Python 客户端


MIT
跨平台
Python

软件简介

Elasticsearch 的 Python
client,提供较为方便的查询语法。

SQL

select * from “ExampleModel” where “name” = “tina”

tina

models, total = ExampleModel.where(‘name’, equal=’tina’).fetch()

SQL select * from “ExampleModel” where “category” = 1 or “category” = 3

order by “created_at” limit 20 offset 20

Python

models, total = ExampleModel.where(‘category’, contains=[1, 3])\
.order_by(‘created_at’).fetch(20, 20)