I am a sublime text lover but at my job I am forced to use Microsoft Visual Studio along with Microsoft SQL Server. I want to possibly just use sublime since I'm quite familiar with it and my workflow is just so much better. To do so I would need to know how to run the SQL queries in sublime text? I have been doing some research and found a couple builds but none that work so I'm wondering if it's even possible if so how?
相关问题
- SQL join to get the cartesian product of 2 columns
- sql execution latency when assign to a variable
- Difference between Types.INTEGER and Types.NULL in
- What is the best way to cache a table from a (SQL)
- php PDO::FETCH_ASSOC doesnt detect select after ba
TSQL Easy is a package you can download which has some tools to run TSQL and SQL scripts. It also has good TSQL syntax highlighting in sublime text 2. Actually it's the only TSQL syntax highlighting I've found so far.
You can get the package here (or through package control): https://github.com/tosher/TSQLEasy
Late to this but was just trying to do the same thing.
A very crude solution I just tested in ST3 uses the following (you need to create a new Build system in ST and then associate it with your SQL file)
It uses a trusted connection to SQL and assumes the sql script will either run as-is in the default database, contains a "USE" statement or table names are otherwise fully qualified.
For additional tweaking, run
sqlcmd /?
from a command prompt or read more hereIt's difficult to create complex IDE from ST2 due it's ascetic UI API.
Even OracleSQL package doesn't give the power of
PL/SQL Developer
orToad
for Oracle.So, maybe it's better to join
SQLMS
withST
. For example write in ST, but run, debug and edit in SQLMS.Here is my setup for using ST and SQLMS together.
ctrl+o,ctrl+s
command: C:\Portable\Sublime Text 2\sublime_text.exe
args: $(ItemPath):$(CurLine):$(CurCol)
dir: $(ItemDir)
"SQL Ex.tmLanguage"
syntax highlight from hereAfter setup you can open same file in ST and SQLMS and switch between editors easily.