I have the following SP which includes a temp table:
DECLARE @pos int
--create table to hold parsed valuesCREATE TABLE #list (val varchar
View Complete Post
Is it possible to change the select, insert and update stored procedure of an SqlDataSource at run time. I don't mean to change the definition of the stored procedure, but I mean to change the assignment, i.e. To change the select stored procedure from "selectSP1" to "selectSP2" at run time. Is it possible?
Language Integrated Query makes lots of things easier. Here we put LINQ, or more specifically the LINQ to SQL provider, to use testing SQL stored procedures.
Dr. James McCaffrey
MSDN Magazine April 2008
Design-time automation makes coding faster and ensures that all the procedures generated use the same naming conventions and structure. In an effort to improve their coding efficiency in a large SQL project, the authors wrote a set of design-time stored procedures that generate run-time stored procedures, and have used them in project after project ever since. Recently, the authors updated their procedures to make use of SQL Server 2000 features, including user-defined functions. This article covers the creation and execution of these dynamic T-SQL scripts to automate the coding of common database stored procedures.
Peter W. DeBetta and J. Byer Hill
MSDN Magazine April 2003
One major inconvenience of using SQL stored procedures from code is having to match type information. You have to write long wrapper functions around the procedures just to expose the data types. In the .NET Framework, however, the reflection services of the System.Reflection namespace allow you to query rich metadata that describe data types. This article explains how to use reflection in .NET to end your stored procedure nightmares. The author creates four custom classes, including one that generates a SQLCommand object based on the metadata of a method. Using this library, you'll be on your way to automating the generation of stored procedures.
MSDN Magazine August 2002
MSDN Magazine June 2002
Edited by Nancy Michell
MSDN Magazine May 2002
Front-end developers frequently want to add functionality to the presentation tier of an n-tier architecture, but such requests can require changes on all tiers just to get the data and present it. This process can be made easier and more flexible by using SQL Server stored procedures to automate the delivery of data in XML format from the database to the front-end components. In the component presented here, stored procedures are invoked by XML strings, XML is returned, converted using XSL, and presented to the client in HTML. The technique supports rapid changes yet doesn't sacrifice the n-tier approach. This approach can be used with either SQL Server 7.0 or SQL Server 2000.
Dave Grundgeiger, Anson Goldade, and Varon Fugman
MSDN Magazine August 2001
I have a database linked to a calendar. I had a peice of code that retrieved dates from a database and populated the calendar. I wanted to tidy up my code using stored procedures (they seem neater & i assume there's a benefit somewhere). so i came up with this, however it's not working. The calendar displays, but it's not being populated with the database entries. The SqlCommand & SqlParameter I have working elsewhere in my code; as with the SqlDataAdapter (which also worked before i tried to conver to a stored procedure!) but combining these three (SqlCommand, SqlParameter & SqlDataAdapter) seem to be causing me problems.
It's probably something stupid but if someone could take a look and point me in the right direction, I'd be very grateful.Cheers,Jim
Public Sub dbConnection()
dbConnString = ConfigurationManager.ConnectionStrings("connString").ConnectionString
sqlConn = New SqlConnection(dbConnString)
Public Sub EquipmentDDLSelection()
Dim dbCMD As New SqlCommand("PopulateCalendar", sqlConn)
dbCMD.CommandType = CommandType.StoredProcedure
Dim parameterBookedEvents As New SqlParameter("@bookedEvents", SqlDbType.VarChar, 50)
i m using below code..by using it i able to write asp data into word file n
format it.but i m facing problen in print out..
it show exception
Message = "The object invoked has disconnected from its clients. (Exception
from HRESULT: 0x80010108 (RPC_E_DISCONNECTED))"
please hav a look at below code....