padrino-gen 迁移 create_indexes 不起作用

发布于 2024-12-08 15:58:51 字数 221 浏览 6 评论 0原文

我正在尝试使用 mongoid_fulltext ,但似乎无法进行迁移来创建所需的索引。当我尝试时:

padrino-gen migration create_indexes 

我得到了结果

apply  orms/mongoid

但是当我清空文档并重建它时,新索引不会显示。我做错了什么吗?

I am trying to use mongoid_fulltext and can't seem to get the migrations to create the indexes needed. When I try:

padrino-gen migration create_indexes 

I get a result

apply  orms/mongoid

But when I empty out a document and rebuild it, the new indexes do not show up. Am I doing something wrong?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

献世佛 2024-12-15 15:58:51

这不是执行命令的正确方法。它更像是 padrino rake mongoid:create_indexes。如果您使用 mongoid 作为 ORM 组件生成项目,那么应该可以工作。运行 padrino rake -T 查看可用任务。

That isn't the correct way to execute the command. It is something more like padrino rake mongoid:create_indexes. If you generated your project with mongoid as the ORM component, that should work. Run padrino rake -T to see the available tasks.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文