Comments (5)
- (NSString *)whc_SqlitePath是绝对路径,因为之前收到有人说想自定义路径放到其他路径下面所以就有这个方法,这个版本号查询没有关系,只要自定义了路径,后面相关操作都是会优先自定义路径来查询然后才是默认路径的。所以没有关系的
+ (NSString *)databaseCacheDirectory:(Class)model_class { if (model_class) { NSString * custom_path = [self exceSelector:@selector(whc_SqlitePath) modelClass:model_class]; if (custom_path != nil && custom_path.length > 0) { return custom_path; } } return [NSString stringWithFormat:@"%@/Library/Caches/WHCSqlite/",NSHomeDirectory()]; }
from whc_modelsqlitekit.
第一个问题是涉及到路径
第二个问题是涉及数据迁移,返回一个字典自动迁移文件,具体看下提交的,不知道那样处理是否正确
from whc_modelsqlitekit.
不需要迁移的,迁移了自定义路径就没有意义了
from whc_modelsqlitekit.
要迁移的吧,以前就使用这个数据的话,都存在默认目录上,自定义以后都是去自定义的路径查找了,需要把原文件移动到自定义目录里面
from whc_modelsqlitekit.
哦你说这个,理论上是的
from whc_modelsqlitekit.
Related Issues (20)
- 主键类型可以设置为字符串类型吗 HOT 1
- 关于demo的线程安全测试问题 HOT 3
- 实现了whc_SqlitePasswordKey协议方法,但数据库貌似没有加密 HOT 1
- 如果指定用户的ID(uid)为主键,插入后自动变为1 HOT 5
- 多个表,如果表名相互有包含关系,会出错 HOT 1
- 关于数据更新问题 HOT 2
- 关于whc_SqlitePasswordKey加密后 无法查看问题 HOT 2
- 数组里面如果是对象无法录入
- 自定义数据库路径查询不到数据 HOT 1
- block 增删改查
- 可以分库么
- demo 都跑不完,玩个毛线,浪费时间
- 如果加入新字段 保存失败 HOT 4
- 建议补充一个方法 HOT 1
- 支持模糊查询吗 HOT 1
- 设置加密后打开数据库就变慢了
- 如何给表设置相应的索引
- 更新表结构
- 不支持自定义主键和设置唯一约束保障同一条数据的唯一性确实是个遗憾
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from whc_modelsqlitekit.