FIND YOUR NEXT FEW LINES

Results for “index”

Small, practical examples. Search by task or narrow things down below.

212 snippets foundClear filters
PostgresSchema design & transactions

Enforce uniqueness with a dedicated index

Postgres: A unique index rejects a duplicate combination independently of query plans.

Postgres✓ Tested
SQLiteSchema design & transactions

Enforce uniqueness with a dedicated index

SQLite: A unique index rejects a duplicate combination independently of query plans.

SQLite✓ Tested
AngularLists & control flow

Expose the current index in @for

Expose the current index in @for with a standalone Angular component and explicit browser behavior.

Angular✓ Tested
CArray transformations

Filter an array in place with a write index

C: Only retained values advance the write position.

C✓ Tested
GoSlices & collections

Find an item’s index

Find an item’s index using a complete Go program with explicit sample inputs.

Go✓ Tested
PowerShellArray operations

Find the index of an array item

PowerShell: Array.IndexOf returns -1 when the requested item is absent.

PowerShell✓ Tested
JavaStream transformations

Index records by a unique key

Java: Use toMap with an explicit merge rule so duplicate keys have defined behavior.

Java✓ Tested
CSSPositioning & stacking

Keep a child’s large z-index inside a stacking context

CSS: Isolation creates a stacking context so an internal stack level cannot outrank an outside sibling’s higher context.

CSS✓ Tested
JavaScriptArray traversal & selection

Read the final array item with a negative index

JavaScript: at supports negative positions counted from the end.

JavaScript✓ Tested
TypeScriptArray traversal & selection

Read the final array item with a negative index

TypeScript: at supports negative positions counted from the end.

TypeScript✓ Tested
Bash ScriptsArray operations

Remove an indexed element and compact the array

Bash Scripts: Unsetting an element leaves a gap; reassigning the values creates consecutive indices.

Bash Scripts✓ Tested
GitStashing selected work

Restore the index state recorded in a stash

Git: Apply with index restores which changes were staged as well as their file contents.

Git✓ Tested