Random Link ¯\_(ツ)_/¯ | ||
Jun 16, 2024 | » | Database Layer
4 min; updated Jun 16, 2024
Currently using MongoDB’s free tier, which has shared RAM, and up to 5GB of storage . So far, the overall DB usage has been less than 5MB. Query Injection Current State of Affairs Currently have this protection implemented back in 2018: /** * @description Prevent a NoSQL Injection in the search parameters. This is * achieved by deleting all query values that begin with `$`. */ export function sanitizeQuery(query: any) { const keys = Object.... |
May 29, 2023 | » | Query Languages for Data
3 min; updated May 29, 2023
Query Languages for Data If you have a list of animal species and you want to return only the sharks in the list, a relational algebra expression would be \( \text{sharks} = \sigma_{\text{family = “Sharks”}}(\text{animals}) \). SQL queries follow the structure of relational algebra closely: SELECT * FROM animals WHERE family = 'Sharks'; … while an imperative query would be: function getSharks() { let sharks = []; for (let i = 0; i < animals.... |