Create a stored procedure with SMO

Once you are connected to SQL Server 2005 with a SMO connection, you can start manage and create object. Here is an example on how you can create a stored procedure, we imagine that we have the code of a stored procedure in an embeded resources file. (this sample is written in C# and use a…

2

Make an ADO.Net connection when you have an SMO connection

When you have an SMO connection, it is very easy to make an ADO.Net connection as the connection string is exactly the same. Then you just have to reuse it. Here is a sample that supposed that the object ServerConn is an SMO ServerConnection.   SqlConnection mySQLConnection;   mySQLConnection = new SqlConnection(ServerConn.ConnectionString); mySQLConnection.Open();


Create table with SMO

Once you are connected to SQL Server 2005 with a SMO connection, you can start manage and create object. Here is an example on how you can create a table with a promary key (this sample is written in C# and use a beta version of SQL Server 2005 and of the .Net Framework 2.0)….


SMO connection

This sample is written in C# and use SQL Server 2005 beta 2 and a beta version of the .Net Framework 2.0. It show how, with SMO you can Connect to SQL Server 2005 In order to connect to SQL Server using SMO you have to reference the following namespace (and the corresponding assembly): using Microsoft.SqlServer.Management.Smo;…


How to retreive KPI from Analysis Services 2005

This sample is written in C# and use SQL Server 2005 beta 2 and a beta version of the .Net Framework 2.0. It show how, with ADOMD.Net, you can retreive KPI that are defined in Analysis Services 2005. 1) reference the namespace for ADOMD: using Microsoft.AnalysisServices.AdomdClient; 2) Build your connection string and connect to Analysis…

6

First Post and presentation

Hi, I am Olivier PIERI, a Microsoft consultant specialized in database technologies. The goals of this blog is discuss about database and Data access technologies offered by Microsoft.Net  Framwork such as ADO.Net, ADOMD.Net and SMO. I will put some sample code about new possibilities offer by the .Net framework 2.0 and SQL Server 2005. Have fun….