We are slowly adding support for SQL in sealious (Probably Postgresql is going to be first sql suported). Next step is to add new method in all Query classes that will compile "mongo objects" to sql strings. This strings are supposed to be Prepared statement. Tests already exist for this functionality and were added in this commit:
https://hub.sealcode.org/rSfc2e5d74e37f1232d4ed0611dd2b9ce50124d75e
https://node-postgres.com/features/pooling
https://www.commandprompt.com/education/how-the-prepare-statement-works-in-postgresql/
These tests will need some adjustments. At the moment it expects SQL string insteand of Prepared statement and uses toPipeline method. We should create new method as toPipeline works for mongo and this method should return object with Prepared statement string and array of parameters to pass.
Next tasks will appear in the future since we are designing this solution on the spot. We have also original task that is now obsolete but it can have some useful information for the future T2150