Is it better to have 100 small hash tables or one big hash table, in memory, in terms of access speed (assuming both fit within RAM)? What do you think about in-database analytics?
Is it better to have 100 small hash tables or one big hash table, in memory, in terms of access speed (assuming both fit within RAM)? What do you think about in-database analytics?
Hash tables:
- Average case O(1)O(1) lookup time
- Lookup time doesn't depend on size
Even in terms of memory:
- O(n)O(n) memory
- Space scales linearly with number of elements
- Lots of dictionaries won't take up significantly less space than a larger one
In-database analytics:
- Integration of data analytics in data warehousing functionality
- Much faster and corporate information is more secure, it doesn't leave the enterprise data warehouse
Good for real-time analytics: fraud detection, credit scoring, transaction processing, pricing and margin analysis, behavioral ad targeting and recommendation engines