Production engineering
using System;
using System.Linq;
using System.Collections.Generic;
using System.Globalization;
using System.Text;
using System.Text.Json;
using System.Threading;
using System.Threading.Tasks;
var rows=new[]{new Product(1,"Rune",30,true),new Product(2,"rune",10,true),new Product(3,"Sword",20,false),new Product(4,"Shield",20,true),new Product(5,"RUNE",15,false)};
Console.WriteLine("names:"+string.Join(",",rows.Where(x=>x.Name.ToLowerInvariant()=="rune").Select(x=>x.Id))); Console.WriteLine("active:"+string.Join(",",rows.Where(x=>x.Active).OrderBy(x=>x.Price).Select(x=>x.Id)));
record Product(int Id,string Name,int Price,bool Active);
Reveal answer and reasoning
The portable product list includes Rune, rune and RUNE at identifiers one, two and five. Applying ToLowerInvariant to these known ASCII names selects all three, producing names:1,2,5. Filtering active records retains identifiers one, two and four; ordering their prices ten, twenty and thirty produces active:2,4,1. These are real C# operations over supplied records, not SQLite's lower function or NOCASE implementation.
The deliberately narrow character set keeps the logical fixture easy to compare without claiming that Unicode case conversion, collation and normalization are interchangeable between the two environments.
The actual endpoint reports the pinned fixture's lower(name) plan using ix_products_lower_name and its active-ordering plan using ix_products_active_price. It also reports the plan for a NOCASE comparison separately. Validation records those observed index uses against the unchanged owned database, while the ordered books result remains two, three and one from the adjacent composite-index example. Do not infer a measured latency ranking from those descriptive arrays.
They establish what this provider chose for the exact expression and predicate, not how every production distribution or alternative text comparison would be executed.
What a strong answer covers
- Known ASCII normalization selects1,2,5; active price order is2,4,1.
- Expression and partial indexes have exact provider matching and row-coverage contracts.
- Observed plan use does not establish cross-engine Unicode semantics or a speed ranking.
Common pitfall
Assuming logically similar text predicates always match the same expression index.
Follow-up questions
- Which Unicode fixtures would challenge the assumed equality rule?
- What query includes rows intentionally absent from the active-only index?
Self-review
Choose what to revisit. These marks are your own assessment and are separate from lesson completion.