Scheme -> Edit Scheme..." in Xcode and a...">
美文网首页
Xcode查看CoreData SQL日志

Xcode查看CoreData SQL日志

作者: 5eky2 | 来源:发表于2017-06-12 14:11 被阅读38次

Open "Product -> Scheme -> Edit Scheme..." in Xcode and add to "Arguments Passed on Launch":

-com.apple.CoreData.SQLDebug3

-com.apple.CoreData.SQLDebug3-com.apple.CoreData.Logging.stderr1

(The second launch argument is needed for Core Data debugging on iOS 10/macOS 10.12 or later, seecom.apple.CoreData.SQLDebug not workingfor more information.)

The you'll see all the values that the SQL statements are bound to. Example output:

test56[1588:c07]CoreData:sql:BEGINEXCLUSIVE

test56[1588:c07]CoreData:sql:INSERTINTOZEVENT(Z_PK,Z_ENT,Z_OPT,ZTIMESTAMP)VALUES(?,?,?,?)test56[1588:c07]CoreData:details:SQLite bind[0]=(int64)13test56[1588:c07]CoreData:details:SQLite bind[1]=(int64)1test56[1588:c07]CoreData:details:SQLite bind[2]=(int64)1test56[1588:c07]CoreData:details:SQLite bind[3]="368650709.435904"test56[1588:c07]CoreData:sql:COMMIT

相关文章

  • Xcode查看CoreData SQL日志

    Open "Product -> Scheme -> Edit Scheme..." in Xcode and a...

  • CoreData 简单使用

    0.0 coredata 相关术语及简介, 1.查看运行时的sql语句,在Product-Scheme-Edit ...

  • 代理无法启动

    方法列表: 重启代理 开启 Window EventLog 查看作业日志 作业活动监视器 展开错误日志 查看SQL...

  • 随笔

    查看手机 crash log 日志 7.x 的机型,7.x 的 Xcode。Xcode -> Window -> ...

  • 解析binlog 常用命令

    一、MySQL命令(sql) 查看是否开启binlog 查看binlog存放位置 查看binlog日志列表 二、使...

  • laravel 打印数据库执行语句

    开启日志 查询执行后的语句 单条查看执行SQL记录 监听所有执行的SQL语句

  • iOS的bug调试

    一、查看Crash Report 通过Xcode的Devices中把crash日志导出来:image.png 查看...

  • Xcode 8 使用CoreData报错linker comma

    Xcode 8.3.3 使用 CoreData在 create NSManagerObject subclass ...

  • mysql 开启binlog

    先登录mysql,查看看binlog日志是否开启 开启binlog日志: 退出当前sql指令: 在my.cnf文件...

  • 查看真机的log日志

    查看模拟器的log日志,可以直接通过Xcode查看,有时,可能需要查看真机的log日志,那么就需要第三方的工具来进...

网友评论

      本文标题:Xcode查看CoreData SQL日志

      本文链接:https://www.haomeiwen.com/subject/lwelqxtx.html