When performing a dynamic query, RavenDB will typically create a temp index.
Retrieving document by its Id
doesn't trigger this behaviour:
var entity = documentSession.Query<Entity>().Single(x => x.Id == 1);
Does RavenDB have a built-in optimisation for this type of query?
Arnold, No, it does not optimize this behavior.
Your assumption is wrong, because it will create a temp index. If your example its name should be "Temp/Entities/By__document_id"
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With