* Given a collection and index name, returns the index details for the index * if it is ready to be used. If the index is not ready, returns NULL. */
| 976 | * if it is ready to be used. If the index is not ready, returns NULL. |
| 977 | */ |
| 978 | IndexDetails * |
| 979 | IndexNameGetReadyIndexDetails(uint64 collectionId, const char *indexName) |
| 980 | { |
| 981 | const char *cmdStr = FormatSqlQuery( |
| 982 | "SELECT index_id, index_spec, FALSE AS index_build_in_progress " |
| 983 | "FROM %s.collection_indexes WHERE collection_id = $1 AND" |
| 984 | " (index_spec).index_name = $2 AND" |
| 985 | " index_is_valid", |
| 986 | ApiCatalogSchemaName); |
| 987 | return IndexNameGetIndexDetailsCore(cmdStr, collectionId, indexName); |
| 988 | } |
| 989 | |
| 990 | |
| 991 | /* |
no test coverage detected