Introduction How to run a SQL query using command prompt without SQL SSMS Open CMD from Run and run the…