Write from mssql server filestream varbinary(max) to filesystem

Hi, I want to do a small poc in rust,

i need to query a mssql server filestream filetable. The sql is not important, more the rust stuff, as i am a total noob, coming from golang. Like what is a good trusted interface/driver for mssql? Is the standard tiberius? And how do i write varbinary(max) to disk?

My objectives are

I need all records between start_date and end_date

  1. write the row's varbinary(max) column content to a certain location on disk

  2. write associated metadata about the row's varbinary to stdout (like file_extension, filename, created_at, uuid etc.)

  3. clear error handling

I have a hard time finding really good sources or tutorials associated with rust and database interaction?

Thank you so much

For interacting with SQL databases, you could either use sqlx or diesel. Check their repositories for examples, and if you're still stuck after that you are always welcome to ask more questions.