Visual Studio 2012 and SQL Server

Status
Not open for further replies.

krtola

Ars Scholae Palatinae
1,205
Hello guys,

I need a little bit help. I have a visual basic script that needs to be modified. The script itself runs against our two SQL 2000 Servers in production pulls data from various data bases and compiles it and sends it out. What i need to do is add an additional SQL server to script so that more data can be pulled.

My situation, i am new to visual scripting and visual studio. I want to set up an environment where i can execute this script. I have downloaded visual studio 2012.

My question, is it possible to set up a connection in visual studio to production Sql data base servers so that i can compile/execute this script successfully in visual studio? And is this the best approach to do this?


Thanks,
Nermin
 

upstateal

Ars Scholae Palatinae
1,013
VBScript isn't really supported/handled by Visual Studio. Have a look here at a bit of a workaround: http://social.msdn.microsoft.com/Forums ... 0e806664c8

Most people writing VBScript do so in a basic text editor with syntax highlighting, and execute the script from within it (if their editor can call an external program) via cscript.exe or wscript.exe - or they just run it by double-clicking in Explorer, or cscript.exe myscript.vbs on a command prompt.

It sounds like this would be a task better suited to SSIS, but being that you're stuck w/ SQL Server 2000 you'd have to use DTS instead (unless you have a newer server that you can run SSIS on, pointing at those 2000 servers), and no one wants to use DTS anymore.

Windows Script Host (VBScript & JScript) is being replaced pretty quickly by PowerShell, but if you can't justify a rewrite, there's no reason to not keep on keepin' on.
 

ShuggyCoUk

Ars Legatus Legionis
10,387
Subscriptor++
I knew people who were ecstatic about that limitation going. They were immediately onto the IT department to get upgraded.

It must have been a shedload of internal work for MS to get it done (especially for the VBA side of things) but it totally kept them in the game, and rendered interoperability with many competitors redundant overnight. You can read our sheets, but you can't use them because of *your* limitations, not our business practices - genius.
 

AndrewZ

Ars Legatus Legionis
11,860
Question to Nermin: Do you really mean 'visual script' or do you mean Visual Basic? Most applications are written in Visual Basic, which is supported in Visual Studio, as Visual Basic .NET, which is a bit different than Visual Basic 6 which is really old but still popular. Visual Basic for Applications, or VBA, or visual scripting, is done inside the application to be scripted, not in Visual Studio.

Using VBA inside Excel you can run SQL statements and put the result set into tables. But you have a lot less control.

Just putting this out there in case it might clarify something.
 
Status
Not open for further replies.