开发者

Execute SQL Script within Solution Explorer in VS 2008 Professional

开发者 https://www.devze.com 2022-12-19 06:35 出处:网络
Does anybody know how I can execute a .sql file from within solution explorer in VS 2008 Professional?

Does anybody know how I can execute a .sql file from within solution explorer in VS 2008 Professional?

I know you can do this开发者_如何学JAVA in VS 2005 but cannot find this feature in VS 2008 professional


If it's within a database project, then you can right click on it and choose "Run" or "Run On...".


Use the "Server Explorer" (Ctrl+W, L) to add a connection, then once a connection is open you can right-click the server node and select "New Query". This will allow you to paste in the contents of an SQL file.

Alternatively open the SQL file, then from the "T-SQL Editor" toolbar you can choose "Connect" from your saved connections, and then select the database in the drop-down box.


According to this link you go to menu Data->Transact-SQL Editor->New Query Connection I think you can figure out the rest by yourselves.

0

精彩评论

暂无评论...
验证码 换一张
取 消