V2EX = way to explore
V2EX 是一个关于分享和探索的地方
现在注册
已注册用户请  登录
推荐学习书目
Learn Python the Hard Way
Python Sites
PyPI - Python Package Index
http://diveintopython.org/toc/index.html
Pocoo
值得关注的项目
PyPy
Celery
Jinja2
Read the Docs
gevent
pyenv
virtualenv
Stackless Python
Beautiful Soup
结巴中文分词
Green Unicorn
Sentry
Shovel
Pyflakes
pytest
Python 编程
pep8 Checker
Styles
PEP 8
Google Python Style Guide
Code Style from The Hitchhiker's Guide
myyou
V2EX  ›  Python

xlsx 能不能像 csv 一样支持边写入边下载?

  •  
  •   myyou · 2017-11-30 11:56:23 +08:00 · 2653 次点击
    这是一个创建于 2344 天前的主题,其中的信息可能已经有所发展或是发生改变。
    8 条回复    2017-11-30 16:29:33 +08:00
    araraloren
        1
    araraloren  
       2017-11-30 12:54:19 +08:00
    xlsx is too complicated than csv
    Maybe you can write your date to csv, and then convert it to xlsx format.
    andyhuzhill
        2
    andyhuzhill  
       2017-11-30 13:00:04 +08:00
    xlsx 本质上是一个 zip 压缩的 xml 文件 而 csv 就是一个文本文件而已
    jasontse
        3
    jasontse  
       2017-11-30 13:00:28 +08:00 via iPad
    应该没办法实现数据流把,它的本质是个 zip 里面一堆 xml。
    metorm
        4
    metorm  
       2017-11-30 13:26:33 +08:00 via Android
    边解析边下载我懂,求教楼主边写边下载是个什么概念?
    myyou
        5
    myyou  
    OP
       2017-11-30 13:54:06 +08:00
    @metorm 就是把向 xlsx 一行一行写入数据转换为数据流,而不是在本地把所有数据全部写入 xlsx 再传输
    gstqc
        6
    gstqc  
       2017-11-30 14:12:38 +08:00
    这需求还是上数据库吧
    zlowly
        7
    zlowly  
       2017-11-30 14:29:39 +08:00   ❤️ 1
    metorm
        8
    metorm  
       2017-11-30 16:29:33 +08:00 via Android
    @zlowly 摩拜干货大佬
    关于   ·   帮助文档   ·   博客   ·   API   ·   FAQ   ·   我们的愿景   ·   实用小工具   ·   811 人在线   最高记录 6543   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 25ms · UTC 22:10 · PVG 06:10 · LAX 15:10 · JFK 18:10
    Developed with CodeLauncher
    ♥ Do have faith in what you're doing.