如何在FMDB SQLite中复制FMResultset [英] How to take copy of FMResultset in FMDB Sqlite

查看:50
本文介绍了如何在FMDB SQLite中复制FMResultset的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我试图从方法中返回FMResult对象的引用,并尝试访问返回的对象中的值,但无法访问.

I tried to return the reference of FMResult object from a method and trying to access values from the returned object and couldn't able to access.

任何人都可以建议如何从方法返回FMResult对象并从外部访问它.

So can anyone suggest how to return the FMResult object from method and access it from outside.

预先感谢.....

推荐答案

您可以在其他地方使用对FMResultSet的引用,但是必须在运行原始查询的同一线程上使用它.

You can use a reference to a FMResultSet elsewhere, however it must be used on the same thread where the original query was ran.

此外,您只能对结果集进行一次迭代.迭代后,它将自动关闭sqlite语句,并且您将不再能够访问结果.

Also, you can only iterate over the result set once. After you iterate, it will automatically close the sqlite statement and you will no longer be able to access the results.

如果这没有任何提示,请张贴所有相关代码.

If that doesn't give you any clues, post all the relevant code.

这篇关于如何在FMDB SQLite中复制FMResultset的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆