vapor / fluent

Vapor ORM (queries, models, and relations) for NoSQL and SQL databases
https://docs.vapor.codes/4.0/fluent/overview/
MIT License
1.3k stars 171 forks source link

How to export data to a file #735

Closed vcxk closed 2 years ago

vcxk commented 2 years ago

Help, I want to export select data to a file in Postgres

\o /path/to/file select * from table \o

and ,how can I do this in fluent; Thank you

0xTim commented 2 years ago

This is not something Fluent supports and is out of scope for the library. You can either run a Fluent query to get the data you want and save that using FileIO or shell out to something like pgdump.