Invoke-SqlQuery is the proper term I believe.
https://www.virtualizationhowto.com/2019/07/how-to-query-a-mysql-database-with-powershell/