types.py 文件源码

python
阅读 19 收藏 0 点赞 0 评论 0

项目:rucio 作者: rucio01 项目源码 文件源码
def process_bind_param(self, value, dialect):
        if value is None:
            return value
        elif dialect.name == 'postgresql':
            return str(value).lower()
        elif dialect.name == 'oracle':
            return uuid.UUID(value).bytes
        elif dialect.name == 'mysql':
            return uuid.UUID(value).bytes
        else:
            if not isinstance(value, uuid.UUID):
                return "%.32x" % uuid.UUID(value)
            else:
                # hexstring
                return "%.32x" % value
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号