MCPcopy Create free account
hub / github.com/documentdb/documentdb / IndexNameGetIndexDetails

Function IndexNameGetIndexDetails

pg_documentdb/src/metadata/index.c:995–1006  ·  view source on GitHub ↗

* IndexNameGetIndexDetails returns IndexDetails for the index with given * "name" using SPI. Returns NULL If no such index exists. */

Source from the content-addressed store, hash-verified

993 * "name" using SPI. Returns NULL If no such index exists.
994 */
995IndexDetails *
996IndexNameGetIndexDetails(uint64 collectionId, const char *indexName)
997{
998 const char *cmdStr = FormatSqlQuery(
999 "SELECT index_id, index_spec, %s.index_build_is_in_progress(index_id) "
1000 "FROM %s.collection_indexes WHERE collection_id = $1 AND"
1001 " (index_spec).index_name = $2 AND"
1002 " (index_is_valid OR %s.index_build_is_in_progress(index_id))",
1003 ApiInternalSchemaName, ApiCatalogSchemaName,
1004 ApiInternalSchemaName);
1005 return IndexNameGetIndexDetailsCore(cmdStr, collectionId, indexName);
1006}
1007
1008
1009static List *

Calls 2

FormatSqlQueryFunction · 0.85

Tested by

no test coverage detected