会员
周边
新闻
博问
闪存
众包
赞助商
Chat2DB
所有博客
当前博客
我的博客
我的园子
账号设置
会员中心
简洁模式
...
退出登录
注册
登录
追星骑士
博客园
首页
新随笔
联系
订阅
管理
2019年1月8日
Python 格式化
摘要: 数字前面补0 字符型: print('23'.zfill(5)) 数字型: print('%011d' % 124) 日期与str互转: datetime 转 str str_date = datetime.now().strftime("%Y-%m-%d") (%04d%02d%02d)此种格式化
阅读全文
posted @ 2019-01-08 16:39 追星骑士
阅读(245)
评论(0)
推荐(0)
2018年12月27日
python输出mssql 查询结果示例
摘要: # -*- coding: utf-8 -*-# python 3.6import pymssql conn=pymssql.connect(host='*****',user='******',password='*******',database='****') ''' 如果和本机数据库交互,只需修改链接字符串 conn=pymssql.connect(host='.',database=...
阅读全文
posted @ 2018-12-27 13:15 追星骑士
阅读(3051)
评论(0)
推荐(0)
公告