V2EX = way to explore
V2EX 是一个关于分享和探索的地方
Sign Up Now
For Existing Member  Sign In
• 请不要在回答技术问题时复制粘贴 AI 生成的内容
smallghost
V2EX  ›  程序员

QT 中为什么读取 sqlite 的 blob 字段内容和实际数据库中得内容不一样

  •  
  •   smallghost · Jun 5, 2014 · 4197 views
    This topic created in 4356 days ago, the information mentioned may be changed or developed.
    代码其实很简单:
    QSqlQuery query(db);
    query.exec("select blobfield from img");
    query.first();
    QByteArray bytes = query.record().value(0).toByteArray();
    这里得到的bytes数据 和 用数据库工具中看到的内容不一样。我用delphi把数据导出来看和数据库工具看得一模一样的,是不是还有什么选项需要设置呀?
    No Comments Yet
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   3045 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 25ms · UTC 07:49 · PVG 15:49 · LAX 00:49 · JFK 03:49
    ♥ Do have faith in what you're doing.