Import file from a database

I currently have an algorithm that uses an excel file that is on my computer to run. I would like to know if it is possible to send this file to a database and then use my algorithm to read this file from the database? If so, do you have an example to show me? Sorry if it's a simple question. I'm new in R language.

Thanks!

Yes. Have a look at packages like DBI , odbc and dplyr.

https://db.rstudio.com/r-packages/dbi/

https://db.rstudio.com/r-packages/odbc/

https://cran.r-project.org/web/packages/dbplyr/vignettes/dbplyr.html