SubSonic 3.0 迁移对比。 SimpleRepository 自动迁移:外键支持?
我正在考虑使用 SubSonic 创建和访问 SQLite 数据库。 尽管我更喜欢 SimpleRepository 方法,但不确定哪种风格更适合我。 事实上,我并不期望我的数据库除了存储我的对象和基本查询之外还能做更多的事情。
我已经阅读了文档,但仍有几点不清楚,或者我想确认:
1/“3.0 迁移”是否完全支持 SQLite ?
2/ 使用 SimpleRepository,自动迁移功能是否等同于“常规”迁移功能,还是仅支持其中的一个子集(除了增量方面)?
3/ 特别是,如何像使用 Migration.CreateForeignKey(TableColumn oneTable, TableColumn ManyTable) 那样指定外键? 我希望使用 [SubSonicForeignKey(Table, Column)] 属性来标记属性,以帮助关系导航并为列建立索引。
我想我在做梦,到目前为止我找到的最好的解决方案就像这篇文章中描述的那样: http://www.frozenmountain.com/ blog/post/Automatic-Foreign-Objects-in-SubSonic3-SimpleRepository.aspx
4/ 但这仍然无法解决缺失的索引。那么 Subsonic 团队:有一天有机会看到 [SubSonicIndex] 属性吗?
谢谢!
I'm considering using SubSonic to create and access an SQLite database.
Not sure yet what flavor fits better for me though I tend to prefer the SimpleRepository approach.
Indeed I don't expect my DB to do much more than storing my objects and basic querying.
I've been through to docs but there are still a few points unclear to me or that I'd like to have confirmation for:
1/ Does "3.0 Migrations" fully support SQLite ?
2/ Using SimpleRepository, is the auto-migration feature equivalent to the 'regular' migration feature or does it support only a subset of it (apart from the incremental aspect) ?
3/ In particular, how can one specify a foreign key like it can be done with Migration.CreateForeignKey(TableColumn oneTable, TableColumn manyTable)?
I would love a [SubSonicForeignKey(Table, Column)] attribute to flag a property as such for helping relationship navigations and also indexing the column.
I suppose I'm dreaming, and the best solution I've found so far is like described in this post:
http://www.frozenmountain.com/blog/post/Automatic-Foreign-Objects-in-SubSonic3-SimpleRepository.aspx
4/ But this still can't address the missing index. So to the Subsonic Team: Any chance to see a [SubSonicIndex] attribute some day?
Thanks!
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论