-
Sep 12th, 2017, 10:06 PM
#1
Thread Starter
Fanatic Member
Stored Procedure to VB code generator?
Hello,
does anybody have an info?
Looking for tool commercial or open source, to create vb module or class code, from sql server (2008 R2 and newer) stored procedures.
There exists one tool SP2VB by Danny Lesandrini, but it does not work nowadays as SQL Namespace objects are missing from the all MS redistributable packages.
www.databasejournal.com/features/mssql/article.php/1494191/Utility-to-Build-VB-Class-to-Match-SQL-Stored-Procedures.htm
Application references SQLDMO and SQLNamespace object libraries.
Code:
Reference= 10010001-E260-11CF-AE68-00AA004A34D5 8.0 SQLDMO.DLL Microsoft SQLDMO Object Library
Reference= 00026F30-EB1C-11CF-AE6E-00AA004A34D5 7.0 sqlns.RLL Microsoft SQLNamespace Object Library
SQLDMO is installed and referenced ok by downloading SQL Server 2005 Backward Compatibility Components, but it seems that the SQLNamespace is not included any of the MS packages anymore. I don't dare to try to install SQL2000 version MSDE components either.
-
Sep 14th, 2017, 08:04 AM
#2
Re: Stored Procedure to VB code generator?
Perhaps you can replace all SQLDMO functions with the system stored procedures (the names start with xp_ and sp_).
Last edited by dreammanor; Sep 14th, 2017 at 08:08 AM.
-
Sep 14th, 2017, 08:39 AM
#3
Re: Stored Procedure to VB code generator?
Originally Posted by dreammanor
Perhaps you can replace all SQLDMO functions with the system stored procedures (the names start with xp_ and sp_).
That's not the same thing... SQLDMO provides functionality beyond just system sprocs... the DMO stands for Database Management Object ... it provides access to things like being able to enumerate SQL Servers on the network, Attach/Detach databases, Backup/Restore, creating & executing SSIS Packages, Maintenance plans... all sorts of things you can't just simply replace with a stored proc. So sadly, it's just not that simple.
Let me clarify that... what I just stated was a blanket statement... I guess in this case the functionality of SQLDMO could be replaced by the use of some system sprocs and a few other clever tricks. Hmmm....
-tg
-
Sep 14th, 2017, 12:35 PM
#4
Thread Starter
Fanatic Member
Re: Stored Procedure to VB code generator?
One (maybe most convenient) option is to rewrite SP2VB app procedure parser. Extract procedures from database to separate sql files and read/parse them to vb code without SQLDMO objects.
-
Sep 14th, 2017, 12:52 PM
#5
Re: Stored Procedure to VB code generator?
-
Sep 14th, 2017, 12:57 PM
#6
Thread Starter
Fanatic Member
Re: Stored Procedure to VB code generator?
Yes, that is known, but it seems that SMO has managed code callable objects only.
-
Sep 14th, 2017, 01:15 PM
#7
Re: Stored Procedure to VB code generator?
You can try to search and download the
- Microsoft SQL Server XXX Backward Compatibility Components
where XXXX is the your SQL Server version, example:
for SQL Server 2005
https://www.microsoft.com/en-us/down....aspx?id=24793
for SQL Server 2008
https://www.microsoft.com/en-us/down...s.aspx?id=6375
-
Sep 14th, 2017, 01:30 PM
#8
Thread Starter
Fanatic Member
Re: Stored Procedure to VB code generator?
2008 version is .net only and do not contain namespace objects either.
Backward Compatibility Components packs (included in feature pack) do contain SQL-DMO, but no namespace objects and it is the Microsoft SQL Server 2005 Backward Compatibility Components installer msi which has SQL-DMO.
Last edited by Tech99; Sep 14th, 2017 at 01:38 PM.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|