【问题标题】:Create sparse index on MongoDB using official C# driver使用官方 C# 驱动程序在 MongoDB 上创建稀疏索引
【发布时间】:2011-08-10 13:39:58
【问题描述】:

官方 C# 驱动程序提供了指定对哪些字段进行 asc、desc 和 geo 排序的功能。它不提供稀疏。

如何直接从 C# 执行此操作?

【问题讨论】:

  • 你的意思是稀疏而不是部分?部分索引(尚未)实现。
  • 谢谢@Remon - 我更正了这个问题。

标签: mongodb mongodb-.net-driver


【解决方案1】:

1.1.驱动程序在 IndexBuilder 中有SetSparse

【讨论】:

  • 谢谢。可以做复合索引吗?
  • 是的,IndexKeysDocument。阅读 API 先生 ;)
猜你喜欢
  • 1970-01-01
  • 2018-12-17
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 2013-06-07
  • 1970-01-01
  • 2018-06-12
  • 1970-01-01
相关资源
最近更新 更多