You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Database is backed by pile. Can have many spaces+indexes
System segment, stores collection and index metadata
When collection dropped - record from sys is erased (instant action)
Data and indexes are stored as pile records
Each record has 2-4 byte metatag - a number in system table collection/index name
Vacuum process goes through all records in pile and deallocates memory for metatags which do not exist
Indexes: single/compound fields, conditional (only index if expression is met)
Documents stored using BIX/Binary
Object allocated with X% padding for in-place changing (table option)
Query: API only. Use LINQ. Use index hash-joins for multiple indexes
Query: handlers (stored procs) written in C#, deployed as assemblies on server (UNISTACK)
Query: RPC-based proc invocation with NAME(params...): object pattern ala MVC
Example:
usingvardb= PileDb.Mount("/home/sky/data/test-db");//.....usingvarrichest= db["customer"]["idx_dob"].GetRange(DateTime(1,1,1980), DateTime(1,1,1990)).Where(one => one.Married).Max(one => one.Income);
Console.WriteLine("The richest married customer is ${richest.FullName} making ${richest.Income}");
Despite what many would expect, the use of LINQ/extensions will work much faster on the server as that is what SQL does internally, only SQL does not know how to process data using primitives like indexes and open table scans, so it has to rely on statistics, whereas a custom written query in C# will outperform any "automatic" query as it is constructed around the specific database primitives (such as specific indexes) known to developer.
The text was updated successfully, but these errors were encountered:
NAME(params...): object
pattern ala MVCExample:
Despite what many would expect, the use of LINQ/extensions will work much faster on the server as that is what SQL does internally, only SQL does not know how to process data using primitives like indexes and open table scans, so it has to rely on statistics, whereas a custom written query in C# will outperform any "automatic" query as it is constructed around the specific database primitives (such as specific indexes) known to developer.
The text was updated successfully, but these errors were encountered: