Peewee 3.2.5 发布,轻量级 Python ORM 库

栏目: 软件资讯 · 发布时间: 7年前

内容简介:Peewee 3.2.5 已发布,Peewee 是一个轻量级的 python ORM 库,内置对 SQLite、MySQL 和 PostgreSQL 的支持。支持 Python 2.7+ 和 Python 3.4+。 更新内容: 新增 ValuesList ,示例如下: data = [(1, 'fi...

Peewee 3.2.5 已发布,Peewee 是一个轻量级的 python ORM 库,内置对 SQLiteMySQL 和 PostgreSQL 的支持。支持 Python 2.7+ 和 Python 3.4+。

更新内容:

  • 新增 ValuesList ,示例如下:

data = [(1, 'first'), (2, 'second')]
vl = ValuesList(data, columns=('idx', 'name'))

query = (vl
         .select(vl.c.idx, vl.c.name)
         .order_by(vl.c.idx))
# Yields:
# SELECT t1.idx, t1.name
# FROM (VALUES (1, 'first'), (2, 'second')) AS t1(idx, name)
# ORDER BY t1.idx
  • DateTimeField、 DateField 和 TimeField 会在发送至数据库之前解析格式化字符串(formatted-string)。

了解更多详情可查阅更新日志

源码下载:


【声明】文章转载自:开源中国社区 [http://www.oschina.net]


以上所述就是小编给大家介绍的《Peewee 3.2.5 发布,轻量级 Python ORM 库》,希望对大家有所帮助,如果大家有任何疑问请给我留言,小编会及时回复大家的。在此也非常感谢大家对 码农网 的支持!

查看所有标签

猜你喜欢:

本站部分资源来源于网络,本站转载出于传递更多信息之目的,版权归原作者或者来源机构所有,如转载稿涉及版权问题,请联系我们

Complexity and Approximation

Complexity and Approximation

G. Ausiello、P. Crescenzi、V. Kann、Marchetti-sp、Giorgio Gambosi、Alberto M. Spaccamela / Springer / 2003-02 / USD 74.95

This book is an up-to-date documentation of the state of the art in combinatorial optimization, presenting approximate solutions of virtually all relevant classes of NP-hard optimization problems. The......一起来看看 《Complexity and Approximation》 这本书的介绍吧!

在线进制转换器
在线进制转换器

各进制数互转换器

图片转BASE64编码
图片转BASE64编码

在线图片转Base64编码工具

UNIX 时间戳转换
UNIX 时间戳转换

UNIX 时间戳转换