Testing A Stored Procedure With Output Params In SQL Server Managment Studio

Sep 25, 2007

I have an SP like this (edited for brevity):

set ANSI_NULLS ON
set QUOTED_IDENTIFIER ON
GO

ALTER PROCEDURE [dbo].[TESTING_SP]
@Username MediumText,
@Password MediumText,
@UserKey int OUTPUT,
@RoleKey int OUTPUT,
@UserGroupKey int OUTPUT,

AS

BEGIN

SELECT
@UserKey = UserKey
FROM UserProfile
WHERE Username = @UserName
AND [Password] = @Password
END

I want to execute this sp in Managment Studio (MS) and see what is being returned but I'm getting this error:

Msg 201, Level 16, State 4, Procedure TESTING_SP, Line 0
Procedure 'TESTING_SP' expects parameter '@UserKey', which was not supplied.

How do I set up the output parameters and then select the values in MS for testing purposes?

Thanks a ton for helping a noob.

View 2 Replies


ADVERTISEMENT

SQL Server 2005 Managment Studio Newbie: Can't See Stored Procedure

Oct 3, 2006

I just created a stored procedure in SQL Server 2005 management studio.  I went to my db and expanded the programmability folder then right clicked the stored procedures folder and created a stored procedure.  I saved the procedure as sp_getDistance in the default folder SQL managment studio picked.  Now when I went back to that stored procedure folder I did not see my stored procedure sp_getDistance, all that was there was the system stored procedure folder.  Did I save the stored procedure in the wrong place, or what did I do wrong.  I can't find the procedure anywhere, its just sitting in my My DocumentsSQL Server Management StudioProjectssp_getDistance.sql folder. Thanks,Kyle Spitzer 

View 1 Replies View Related

Problem With OUTPUT Params In Stored Procedure

Jul 23, 2005

Hi all!Running the code below in SQL-analyzeer (or through dbExpress) results in NULL.As one might guess I would like the result to be 1. What is wrong? I.e, whywont the result of the SP come back to the caller?CREATE PROCEDURE test@val INTEGER OUTASSELECT @val = 1GODECLARE @val INTEGEREXEC test @valSELECT @val

View 1 Replies View Related

How To Test Stored Procedure With Output Parameters In Management Studio

Jun 6, 2007

I have this SP:

set ANSI_NULLS ON
set QUOTED_IDENTIFIER ON
GO

ALTER PROCEDURE [dbo].[GetSessionInformation]
@CustomerID int,
@Success bit OUTPUT,
@Email VarChar(55) OUTPUT,
@FirstName VarChar(55) OUTPUT,
@LastName VarChar(50) OUTPUT,
@PhoneNumber VarChar(50) OUTPUT,
@CompanyName VarChar(50) OUTPUT
AS

SET NOCOUNT ON

DECLARE @UserKey AS int

SELECT @CustomerID = CustomerID
FROM Customers
WHERE CustomerID = @CustomerID

IF @CustomerID IS NULL
BEGIN
SET @Success = 0
END
ELSE
BEGIN
SET @Success = 1
END

BEGIN

SELECT customerID, Email, FirstName, LastName, PhoneNumber, CompanyName
FROM Customers
WHERE CustomerID = @UserKey

How do I test it in management studio?

When I run a EXECUTE GetSessionInformation 56

I get this error:
Procedure 'GetSessionInformation' expects parameter '@Success', which was not supplied.

Thanks for any help!

View 2 Replies View Related

Please Help! Cannot See Values In Output Params From SQL Server 2000 Using C# / ASP.NET

May 26, 2004

Hi,

I've got the following C# function to add a customer record to the database. The record gets added without any problems but the OUTPUT PARAMETER (Parameter[10]) is always NULL and I can't see why. I'm also using the Microsoft Data Application Block.

Here's the C# function:

public void SaveCustomer(int customerId,string customerName,string address1,
string address2,
string town,
string county,
string postcode,
string webSiteAddress,
string mainTelNo,
string mainFaxNo)

{
try
{
SqlParameter[] parameters = DA.SqlHelperParameterCache.GetSpParameterSet(this.ConnectionString,"UpdateCustomer");
parameters[0].Value = customerId;
parameters[1].Value = customerName;
parameters[2].Value = address1;
parameters[3].Value = address2;
parameters[4].Value = town;
parameters[5].Value = county;
parameters[6].Value = postcode;
parameters[7].Value = webSiteAddress;
parameters[8].Value = mainTelNo;
parameters[9].Value = mainFaxNo;
parameters[10].Direction = ParameterDirection.Output;

int RetVal = DA.SqlHelper.ExecuteNonQuery(this.Connection,"UpdateCustomer",parameters);

if (RetVal > 0)
{
int Key = Convert.ToInt32(parameters[10].Value.ToString());
}

}
catch (Exception ex)
{
throw new Exception(ex.Message.ToString(), ex);
}

}


And here's the SQL Server 2000 Stored Procedure:


CREATE PROCEDURE UpdateCustomer

@CustomerId int,
@CustomerName varchar(100),
@Address1 varchar(50),
@Address2 varchar(50),
@Town varchar(30),
@County varchar(30),
@PostCode varchar(10),
@WebSite varchar(50),
@MainTelNo varchar(15),
@MainFaxNo varchar(15),
@ReturnValue int OUTPUT

AS

IF @CustomerId = 0
BEGIN
INSERT INTO Customer
(CustomerName, Address1, Address2, Town, County, Postcode, WebSite, MainTelNo, MainFaxNo)
VALUES(@CustomerName, @Address1, @Address2, @Town, @County, @Postcode, @WebSite, @MainTelNo, @MainFaxNo)

IF @@ERROR = 0
BEGIN
SELECT @ReturnValue = @@IDENTITY
END
ELSE
BEGIN
SELECT @ReturnValue = -1
END

END
ELSE
BEGIN
UPDATE Customer
SETCustomerName = @CustomerName,
Address1 = @Address1,
Address2 = @Address2,
Town = @Town,
County = @County,
Postcode = @Postcode,
WebSite = @WebSite,
MainTelNo = @MainTelNo,
MainFaxNo = @MainFaxNo
WHERECustomerId = @CustomerId

IF @@ERROR = 0
BEGIN
SELECT @ReturnValue = @CustomerId
END
ELSE
BEGIN
SELECT @ReturnValue = -1
END
END



Any help would be appreciated as it's starting to drive me mad now!!

View 7 Replies View Related

Statement For Returning Stored Procedure Params

Oct 27, 2005

Hi all,I'd like to put together a SQL statement that will take the name of astored procedure as a param, and return that SP's parameters.I'm writing a test application, and I'd like to wrte a generator tosave myself some time, but I can't seem to figure out how to get theparams from a SP. Any help would be appreciated.Thanks in advance,Craig

View 2 Replies View Related

Sql Server Managment Studio Express Question

Nov 14, 2005

Is there any known issue where SQL Server Management Studio Express CTP just fails to start without an error?

View 2 Replies View Related

Vista, Varbinary(max) And SQL Server Managment Studio

Aug 13, 2007

I'm running into an issue that only occurs on Vista machines against a SQL Server 2005. We have a table with a varbinary(MAX) column in which we store a csv/xls/xml file. When I perform a 'select * from my_table' within Management Studio the column data returned is sporadic...some rows are filled out and some are not. When performed on an XP machine all of the data is returned (every row's column is filled out). Is this a known issue? I tried searching for it but didn't find anything.

Thanks,
Nellie

View 3 Replies View Related

SQL Server Managment Studio Repeated Logins

Jan 11, 2008



Presumably an easy question but every time I open a query file the SSMS requires me to login. Very frustrating. Cannot find a configuration option, properties attribute or other to turn this off. Can anyone adivse how I can set up SMSS to require a login at the beginning of the session and then not again for each saved query I open?

Thanks.

View 3 Replies View Related

Connecting My VB Database To SQL Server Managment Studio?

Jul 1, 2006

hi

i have created a sql database in visual studio pro and now i would like to connect to that database in SQL server managamenet studio. so when i start SQL server i connect to the same instance as my database (wich is .SQLEXPRESS) but i can't find my database in the object explorer?

View 1 Replies View Related

How To Write Database Scripts Using Sql Server Managment Studio

Apr 25, 2008

Hello All,
My boss told me that we can write migration scripts to database using Sql server management studio. can someone guide me or point to a website which explains in detail how to do this please. i want to learn this. or even a tutorial also would be great. i am interested in writing or executing scripts by using sql server management studio( in sql server 2005). i think its called sql enterprise manager in sql server 2000.
Thanks a lot.

View 5 Replies View Related

Creating A New Database With Sql Server Managment Studio Express

May 13, 2008

I have SQL Server 2005 installed with Sql Server Management Studio Express and when I open up the Management Studio program and try to create a new Database Engine I am getting the below errors:
Create failed for Database 'rufnek'.  (Microsoft.SqlServer.Express.Smo)
An exception occurred while executing a Transact-SQL statement or batch. (Microsoft.SqlServer.Express.ConnectionInfo)

View 1 Replies View Related

Sql Server 2005 Managment Studio Crashes Randomly

Jan 4, 2006

Hi all, i am getting these type of errors in the managment tool where i try to look a stored p. or see the schema list or listing tables in a database.

THe errors looks like this one below but it does change in the InvalidArgument=Value of '***' *** area it gets numbers 448 1 5 or something else and after the error management studio doesnt work correctly, in the summory window nothing shows up, .

here is the detailed error message Please help.



 See the end of this message for details on invoking
just-in-time (JIT) debugging instead of this dialog box.

************** Exception Text **************
System.ArgumentOutOfRangeException: InvalidArgument=Value of '448' is not valid for 'index'.
Parameter name: index
   at System.Windows.Forms.ListView.ListViewItemCollection.get_Item(Int32 index)
   at System.Windows.Forms.ListView.set_VirtualListSize(Int32 value)
   at Microsoft.SqlServer.Management.UI.VSIntegration.AppIDPackage.RightPaneListViewer.set_VirtualListSize(Int32 value)
   at Microsoft.SqlServer.Management.UI.VSIntegration.AppIDPackage.RightPaneListViewer.PopulateView()
   at Microsoft.SqlServer.Management.UI.VSIntegration.AppIDPackage.RightPaneListViewer.Microsoft.SqlServer.Management.UI.VSIntegration.AppIDPackage.IReportView.SetReportSource(ReportSource reportSource)
   at Microsoft.SqlServer.Management.UI.VSIntegration.AppIDPackage.RightPaneControl.InternalSetReportSource(ReportSource reportSource, IReportView newView)


************** Loaded Assemblies **************
mscorlib
    Assembly Version: 2.0.0.0
    Win32 Version: 2.0.50727.42 (RTM.050727-4200)
    CodeBase: file:///C:/WINDOWS/Microsoft.NET/Framework/v2.0.50727/mscorlib.dll
----------------------------------------
AppIDPackage
    Assembly Version: 9.0.242.0
    Win32 Version: 9.00.1399.00
    CodeBase: file:///C:/Program%20Files/Microsoft%20SQL%20Server/90/Tools/Binn/VSShell/Common7/IDE/AppIDPackage.DLL
----------------------------------------
System
    Assembly Version: 2.0.0.0
    Win32 Version: 2.0.50727.42 (RTM.050727-4200)
    CodeBase: file:///C:/WINDOWS/assembly/GAC_MSIL/System/2.0.0.0__b77a5c561934e089/System.dll
----------------------------------------
Microsoft.SqlServer.SqlTools.VSIntegration
    Assembly Version: 9.0.242.0
    Win32 Version: 9.00.1399.00
    CodeBase: file:///C:/Program%20Files/Microsoft%20SQL%20Server/90/Tools/Binn/VSShell/Common7/IDE/Microsoft.SqlServer.SqlTools.VSIntegration.DLL
----------------------------------------
Microsoft.VisualStudio.Shell.Interop
    Assembly Version: 7.1.40304.0
    Win32 Version: 7.0.4054
    CodeBase: file:///C:/WINDOWS/assembly/GAC/Microsoft.VisualStudio.Shell.Interop/7.1.40304.0__b03f5f7f11d50a3a/Microsoft.VisualStudio.Shell.Interop.dll
----------------------------------------
Microsoft.VisualStudio.OLE.Interop
    Assembly Version: 7.1.40304.0
    Win32 Version: 7.0.4054
    CodeBase: file:///C:/WINDOWS/assembly/GAC/Microsoft.VisualStudio.OLE.Interop/7.1.40304.0__b03f5f7f11d50a3a/Microsoft.VisualStudio.OLE.Interop.dll
----------------------------------------
System.Windows.Forms
    Assembly Version: 2.0.0.0
    Win32 Version: 2.0.50727.42 (RTM.050727-4200)
    CodeBase: file:///C:/WINDOWS/assembly/GAC_MSIL/System.Windows.Forms/2.0.0.0__b77a5c561934e089/System.Windows.Forms.dll
----------------------------------------
System.Drawing
    Assembly Version: 2.0.0.0
    Win32 Version: 2.0.50727.42 (RTM.050727-4200)
    CodeBase: file:///C:/WINDOWS/assembly/GAC_MSIL/System.Drawing/2.0.0.0__b03f5f7f11d50a3a/System.Drawing.dll
----------------------------------------
Microsoft.SqlServer.SqlTDiagM
    Assembly Version: 9.0.242.0
    Win32 Version: 9.00.1399.00
    CodeBase: file:///C:/WINDOWS/assembly/GAC_MSIL/Microsoft.SqlServer.SqlTDiagM/9.0.242.0__89845dcd8080cc91/Microsoft.SqlServer.SqlTDiagM.dll
----------------------------------------
Microsoft.DataWarehouse.SQM
    Assembly Version: 9.0.242.0
    Win32 Version: 9.00.1399.00
    CodeBase: file:///C:/Program%20Files/Microsoft%20SQL%20Server/90/Tools/Binn/VSShell/Common7/IDE/Microsoft.DataWarehouse.SQM.DLL
----------------------------------------
Microsoft.SqlServer.Instapi
    Assembly Version: 9.0.242.0
    Win32 Version: 9.00.1399.00
    CodeBase: file:///C:/WINDOWS/assembly/GAC_MSIL/Microsoft.SqlServer.Instapi/9.0.242.0__89845dcd8080cc91/Microsoft.SqlServer.Instapi.dll
----------------------------------------
ObjectExplorer
    Assembly Version: 9.0.242.0
    Win32 Version: 9.00.1399.00
    CodeBase: file:///C:/Program%20Files/Microsoft%20SQL%20Server/90/Tools/Binn/VSShell/Common7/IDE/ObjectExplorer.DLL
----------------------------------------
ConnectionDlg
    Assembly Version: 9.0.242.0
    Win32 Version: 9.00.1399.00
    CodeBase: file:///C:/Program%20Files/Microsoft%20SQL%20Server/90/Tools/Binn/VSShell/Common7/IDE/ConnectionDlg.DLL
----------------------------------------
SqlWorkbench.Interfaces
    Assembly Version: 9.0.242.0
    Win32 Version: 9.00.1399.00
    CodeBase: file:///C:/Program%20Files/Microsoft%20SQL%20Server/90/Tools/Binn/VSShell/Common7/IDE/SqlWorkbench.Interfaces.DLL
----------------------------------------
Microsoft.SqlServer.CustomControls
    Assembly Version: 9.0.242.0
    Win32 Version: 9.00.1399.00
    CodeBase: file:///C:/WINDOWS/assembly/GAC_MSIL/Microsoft.SqlServer.CustomControls/9.0.242.0__89845dcd8080cc91/Microsoft.SqlServer.CustomControls.dll
----------------------------------------
Accessibility
    Assembly Version: 2.0.0.0
    Win32 Version: 2.0.50727.42 (RTM.050727-4200)
    CodeBase: file:///C:/WINDOWS/assembly/GAC_MSIL/Accessibility/2.0.0.0__b03f5f7f11d50a3a/Accessibility.dll
----------------------------------------
SqlMgmt
    Assembly Version: 9.0.242.0
    Win32 Version: 9.00.1399.00
    CodeBase: file:///C:/Program%20Files/Microsoft%20SQL%20Server/90/Tools/Binn/VSShell/Common7/IDE/SqlMgmt.DLL
----------------------------------------
Microsoft.SqlServer.RegSvrEnum
    Assembly Version: 9.0.242.0
    Win32 Version: 9.00.1399.00
    CodeBase: file:///C:/WINDOWS/assembly/GAC_MSIL/Microsoft.SqlServer.RegSvrEnum/9.0.242.0__89845dcd8080cc91/Microsoft.SqlServer.RegSvrEnum.dll
----------------------------------------
EnvDTE
    Assembly Version: 8.0.0.0
    Win32 Version: 8.0.50727.42 (RTM.050727-4200)
    CodeBase: file:///C:/WINDOWS/assembly/GAC/EnvDTE/8.0.0.0__b03f5f7f11d50a3a/EnvDTE.dll
----------------------------------------
Microsoft.NetEnterpriseServers.ExceptionMessageBox
    Assembly Version: 9.0.242.0
    Win32 Version: 9.00.1399.00
    CodeBase: file:///C:/WINDOWS/assembly/GAC_MSIL/Microsoft.NetEnterpriseServers.ExceptionMessageBox/9.0.242.0__89845dcd8080cc91/Microsoft.NetEnterpriseServers.ExceptionMessageBox.dll
----------------------------------------
System.Data
    Assembly Version: 2.0.0.0
    Win32 Version: 2.0.50727.42 (RTM.050727-4200)
    CodeBase: file:///C:/WINDOWS/assembly/GAC_32/System.Data/2.0.0.0__b77a5c561934e089/System.Data.dll
----------------------------------------
Microsoft.SqlServer.ConnectionInfo
    Assembly Version: 9.0.242.0
    Win32 Version: 9.00.1399.00
    CodeBase: file:///C:/WINDOWS/assembly/GAC_MSIL/Microsoft.SqlServer.ConnectionInfo/9.0.242.0__89845dcd8080cc91/Microsoft.SqlServer.ConnectionInfo.dll
----------------------------------------
System.Xml
    Assembly Version: 2.0.0.0
    Win32 Version: 2.0.50727.42 (RTM.050727-4200)
    CodeBase: file:///C:/WINDOWS/assembly/GAC_MSIL/System.Xml/2.0.0.0__b77a5c561934e089/System.Xml.dll
----------------------------------------
Microsoft.SqlServer.SmoEnum
    Assembly Version: 9.0.242.0
    Win32 Version: 9.00.1399.00
    CodeBase: file:///C:/WINDOWS/assembly/GAC_MSIL/Microsoft.SqlServer.SmoEnum/9.0.242.0__89845dcd8080cc91/Microsoft.SqlServer.SmoEnum.dll
----------------------------------------
System.Configuration
    Assembly Version: 2.0.0.0
    Win32 Version: 2.0.50727.42 (RTM.050727-4200)
    CodeBase: file:///C:/WINDOWS/assembly/GAC_MSIL/System.Configuration/2.0.0.0__b03f5f7f11d50a3a/System.Configuration.dll
----------------------------------------
System.Transactions
    Assembly Version: 2.0.0.0
    Win32 Version: 2.0.50727.42 (RTM.050727-4200)
    CodeBase: file:///C:/WINDOWS/assembly/GAC_32/System.Transactions/2.0.0.0__b77a5c561934e089/System.Transactions.dll
----------------------------------------
System.EnterpriseServices
    Assembly Version: 2.0.0.0
    Win32 Version: 2.0.50727.42 (RTM.050727-4200)
    CodeBase: file:///C:/WINDOWS/assembly/GAC_32/System.EnterpriseServices/2.0.0.0__b03f5f7f11d50a3a/System.EnterpriseServices.dll
----------------------------------------
Microsoft.SqlServer.Smo
    Assembly Version: 9.0.242.0
    Win32 Version: 9.00.1399.00
    CodeBase: file:///C:/WINDOWS/assembly/GAC_MSIL/Microsoft.SqlServer.Smo/9.0.242.0__89845dcd8080cc91/Microsoft.SqlServer.Smo.dll
----------------------------------------
Microsoft.SqlServer.SqlEnum
    Assembly Version: 9.0.242.0
    Win32 Version: 9.00.1399.00
    CodeBase: file:///C:/WINDOWS/assembly/GAC_MSIL/Microsoft.SqlServer.SqlEnum/9.0.242.0__89845dcd8080cc91/Microsoft.SqlServer.SqlEnum.dll
----------------------------------------
Microsoft.SqlServer.BatchParser
    Assembly Version: 9.0.242.0
    Win32 Version: 2005.090.1399.00
    CodeBase: file:///C:/WINDOWS/assembly/GAC_32/Microsoft.SqlServer.BatchParser/9.0.242.0__89845dcd8080cc91/Microsoft.SqlServer.BatchParser.dll
----------------------------------------
msvcm80
    Assembly Version: 8.0.50608.0
    Win32 Version: 8.00.50727.42
    CodeBase: file:///C:/WINDOWS/WinSxS/x86_Microsoft.VC80.CRT_1fc8b3b9a1e18e3b_8.0.50727.42_x-ww_0de06acd/msvcm80.dll
----------------------------------------
System.Management
    Assembly Version: 2.0.0.0
    Win32 Version: 2.0.50727.42 (RTM.050727-4200)
    CodeBase: file:///C:/WINDOWS/assembly/GAC_MSIL/System.Management/2.0.0.0__b03f5f7f11d50a3a/System.Management.dll
----------------------------------------
ObjectExplorerReplication
    Assembly Version: 9.0.242.0
    Win32 Version: 9.00.1399.00
    CodeBase: file:///C:/Program%20Files/Microsoft%20SQL%20Server/90/Tools/Binn/VSShell/Common7/IDE/ObjectExplorerReplication.DLL
----------------------------------------
Microsoft.ReportViewer.WinForms
    Assembly Version: 8.0.0.0
    Win32 Version: 8.0.50727.42
    CodeBase: file:///C:/WINDOWS/assembly/GAC_MSIL/Microsoft.ReportViewer.WinForms/8.0.0.0__b03f5f7f11d50a3a/Microsoft.ReportViewer.WinForms.dll
----------------------------------------
SQLEditors
    Assembly Version: 9.0.242.0
    Win32 Version: 9.00.1399.00
    CodeBase: file:///C:/Program%20Files/Microsoft%20SQL%20Server/90/Tools/Binn/VSShell/Common7/IDE/SQLEditors.DLL
----------------------------------------
Microsoft.VisualStudio.TextManager.Interop
    Assembly Version: 7.1.40304.0
    Win32 Version: 7.0.4054
    CodeBase: file:///C:/WINDOWS/assembly/GAC/Microsoft.VisualStudio.TextManager.Interop/7.1.40304.0__b03f5f7f11d50a3a/Microsoft.VisualStudio.TextManager.Interop.dll
----------------------------------------
SqlManagerUI
    Assembly Version: 9.0.242.0
    Win32 Version: 9.00.1399.00
    CodeBase: file:///C:/Program%20Files/Microsoft%20SQL%20Server/90/Tools/Binn/VSShell/Common7/IDE/SqlManagerUi.DLL
----------------------------------------
Microsoft.AnalysisServices
    Assembly Version: 9.0.242.0
    Win32 Version: 9.00.1399.00
    CodeBase: file:///C:/WINDOWS/assembly/GAC_MSIL/Microsoft.AnalysisServices/9.0.242.0__89845dcd8080cc91/Microsoft.AnalysisServices.dll
----------------------------------------
Microsoft.SqlServer.GridControl
    Assembly Version: 9.0.242.0
    Win32 Version: 9.00.1399.00
    CodeBase: file:///C:/WINDOWS/assembly/GAC_MSIL/Microsoft.SqlServer.GridControl/9.0.242.0__89845dcd8080cc91/Microsoft.SqlServer.GridControl.dll
----------------------------------------
Microsoft.SqlServer.DlgGrid
    Assembly Version: 9.0.242.0
    Win32 Version: 9.00.1399.00
    CodeBase: file:///C:/WINDOWS/assembly/GAC_MSIL/Microsoft.SqlServer.DlgGrid/9.0.242.0__89845dcd8080cc91/Microsoft.SqlServer.DlgGrid.dll
----------------------------------------
Microsoft.SqlServer.DataStorage
    Assembly Version: 9.0.242.0
    Win32 Version: 9.00.1399.00
    CodeBase: file:///C:/WINDOWS/assembly/GAC_MSIL/Microsoft.SqlServer.DataStorage/9.0.242.0__89845dcd8080cc91/Microsoft.SqlServer.DataStorage.dll
----------------------------------------
System.Design
    Assembly Version: 2.0.0.0
    Win32 Version: 2.0.50727.42 (RTM.050727-4200)
    CodeBase: file:///C:/WINDOWS/assembly/GAC_MSIL/System.Design/2.0.0.0__b03f5f7f11d50a3a/System.Design.dll
----------------------------------------
Microsoft.VisualStudio
    Assembly Version: 2.0.0.0
    Win32 Version: 2.0.50727.42 built by: RTM
    CodeBase: file:///C:/WINDOWS/assembly/GAC_MSIL/Microsoft.VisualStudio/2.0.0.0__b03f5f7f11d50a3a/Microsoft.VisualStudio.dll
----------------------------------------
Microsoft.VisualStudio.Shell
    Assembly Version: 2.0.0.0
    Win32 Version: 2.0.50727.42 (RTM.050727-4200)
    CodeBase: file:///C:/WINDOWS/assembly/GAC_MSIL/Microsoft.VisualStudio.Shell/2.0.0.0__b03f5f7f11d50a3a/Microsoft.VisualStudio.Shell.dll
----------------------------------------
Microsoft.VisualStudio.Shell.Interop.8.0
    Assembly Version: 8.0.0.0
    Win32 Version: 8.0.50727.42 (RTM.050727-4200)
    CodeBase: file:///C:/WINDOWS/assembly/GAC/Microsoft.VisualStudio.Shell.Interop.8.0/8.0.0.0__b03f5f7f11d50a3a/Microsoft.VisualStudio.Shell.Interop.8.0.dll
----------------------------------------
System.Drawing.Design
    Assembly Version: 2.0.0.0
    Win32 Version: 2.0.50727.42 (RTM.050727-4200)
    CodeBase: file:///C:/WINDOWS/assembly/GAC_MSIL/System.Drawing.Design/2.0.0.0__b03f5f7f11d50a3a/System.Drawing.Design.dll
----------------------------------------
Microsoft.VisualStudio.Designer.Interfaces
    Assembly Version: 1.0.5000.0
    Win32 Version: 1.1.4322.573
    CodeBase: file:///C:/WINDOWS/assembly/GAC/Microsoft.VisualStudio.Designer.Interfaces/1.0.5000.0__b03f5f7f11d50a3a/Microsoft.VisualStudio.Designer.Interfaces.dll
----------------------------------------

************** JIT Debugging **************
To enable just-in-time (JIT) debugging, the .config file for this
application or computer (machine.config) must have the
jitDebugging value set in the system.windows.forms section.
The application must also be compiled with debugging
enabled.

For example:

<configuration>
    <system.windows.forms jitDebugging="true" />
</configuration>

When JIT debugging is enabled, any unhandled exception
will be sent to the JIT debugger registered on the computer
rather than be handled by this dialog box.


 

View 8 Replies View Related

Sdf File Edited In SQL Server Managment Studio Crashes My Pocket Pc Application.

Apr 16, 2008

I have a sql server ce db file that I use in my pocket pc application. It seems to be working until I try to edit my .sdf file in SQL Server (2005) Managment Studio. After this I cannot open modified file in my application.

I receive native exception error when I call Open method for Connection object:
ExceptionCode: 0xc0000005
ExceptionAddress: 0x03f8aaac
Reading: 0x00000010

When I edit .sdf file in another pc it's all working.

My config is:
windows vista business
.net compact framework 2.0 sp2
sql server 2005
sql server 2005 compact edition
sql server 2005 compact edition server tools
sql server 2005 compact edition tools for visual studio 2005

Best regards



View 1 Replies View Related

SQL Server Managment Studio Express 2005 Import/Export Wizard

Nov 29, 2006

I've created a new database and restored the database from a backup. I'm wanting to import raw data from an excel spreadsheet into the tables of the new database.

When I right click on the database, and hover over tasks the import/ export data menu options are not in the menu.The menu items ends at 'Generate Scripts'.

I'm connected on a local instance to a registered server.

Can anyone advise?

View 9 Replies View Related

Excel 2007 DataMining Add-in Database On SQL Server 2005 Destroyed By Using SQL Server Managment Studio?

Apr 26, 2007

Hello,



i have made some Data Mining Model Examples in Excel 2007 (not temporarily!). They where there after leaving an re-opening Excel. I have used them several times. Then I want to look, if I can see them also via SQL Server Managment Studio in the Analysis Services. There where nothing in the DMAddInDB in Analysis Services.

And after this, in Excel my DataMining Models have disappeared and all Models i have made since this disappeared also.



Perhaps I have destroyed the database. But will this happen every time? Can I share Data Mining Models I have made with Excel with Projects in SQL Server Analysis Services?



Thanks

Berenice

View 5 Replies View Related

Testing A Stored Procedure?

Feb 26, 2004

Is there a way to test a stored procedure in SQL Server?

TIA

View 1 Replies View Related

Testing For The Existance Of A Stored Procedure In T-sql

Oct 24, 2007

Hi,
I need to test for the existance of a stored proc on a specific database(s) on a server(s), and get the user assigned permissions/roles.
Is there a built in system proc that returns such information?
Thanks,

View 5 Replies View Related

Testing Stored Procedure For Accuracy

May 14, 2008

I am given a task to test a complex stored procedure that has been recently modified for performance. The stored procedure runs 2 processes based on different parameters provided to it in real time. The procedure has been modified to incresease its performance from 22hours to just 1 minute. One of the two processes that this SP handels have been tested and is thus very accurate. The testing of 2nd process is given to me and I am looking for some great help in how to go about testing it step by step. I can provide more info on the SP and how we increased its performance, if you are interested.
I know its a lot to ask but I really need some help. I have limited knowledge in SQL.

View 10 Replies View Related

Dynamic SQL && Output Params

Feb 7, 2005

I have a long running trigger that makes calls to several tables in order to get values for a list of parameters before doing my final INSERT statement into a different table.

One of my parameters is for a local language translation of a particular word which is stored in a table. The problem is - I do not know the name of the table until runtime when I dynamically build the name as follows:


DECLARE @SQL nVarChar(200)
SET @SQL = 'SELECT @Translation = nvcLocalEventDescription FROM Monitoring.dbo.tblSignalTemplate'
+ CAST(@MonitoringCentreID AS nVarChar) + ' WHERE nvcEventDescription = "' + @EventDescription + '"'

EXECUTE Management.dbo.usp_parmsel_LocalEventDescription @SQL, @LocalEventDescription OUTPUT


If there is a MonitoringCentreID of 1234, then there will be a table named tblSignalTemplate1234 - which will contain a nvcLocalEventDescription field containing the value that I am after. Here is the code for the stored procedure...


CREATE PROCEDURE [dbo].[usp_parmsel_LocalEventDescription]
@strSQL nVarchar(150),
@Translation nVarChar(100) OUTPUT
AS
EXECUTE sp_executesql @strSQL
GO


The error I get is "Must declare the variable '@Translation'" - which has thrown me a little as it declared on the 3rd line of the stored proc.

Anyone got any ideas where I am going wrong, or as usual, is there a simpler way ?

Steve.

View 2 Replies View Related

Managment Studio

Feb 28, 2006

Hi

I received the trial 2005 Enterprise edition software to give 2005 a shot. Everything installed fine but no Managment Studio to interface with it. All the documentation I read (like this http://msdn2.microsoft.com/en-us/library/ms174173.aspx ) just expects the software to be there.

I can't find it as a download. Does anyone know what the deal is?

Thanks

View 7 Replies View Related

Promblem With Log In Managment Studio

Oct 30, 2006

hi

Until now I was using SQLServer Express edition and whenever I wanted to log in Management Studio In the Server Name section I used to wirte MyComputernameSQLExpress

but now I'm going to use Enterprise edition

what should I write in the Server Name section to log in Management studio??

View 1 Replies View Related

Can Not Find Managment Studio

Nov 12, 2007

Trying out vista here...

So I installed standard edition of sql server x64 and sp2.

I can only find configuration tools in "All Programs/Microsoft SQL Server 2005/Configuration Tools/4 applications", I give all rights etc to my user, but where is managment studio..?

View 5 Replies View Related

Getting Data (rows) And Output Params From A Query

May 15, 2005

I have a stored procedure that I use to return Purchase Orders from our PO system. It returns the data rows for PO's that match the criteria passed in (including the page to show etc.) + it returns two output params, Number of rows and Number of Pages.
Using query analyzer I can confirm the query works exactly as we want. I cannot however seem to get the data out to our ASP.net app.
Here is a function that I use in one of my classes:
<code>
Function fnListPOsByCoordinatorIDPaged(ByVal strCoordinatorID As String, ByVal intPOStatusID As Int16, _
ByVal intUserTypeID As Int16, ByVal intArchived As Int16, _ByVal intPageNum As Int32, ByVal intPerPage As Int32, _ByVal strConn As String) As SqlClient.SqlDataReader
Dim dr As SqlClient.SqlDataReader
SqlConnection1.ConnectionString = strConn
prListPOByCoordinatorPaged.Parameters("@CoordinatorID").Value = strCoordinatorIDprListPOByCoordinatorPaged.Parameters("@POStatusID").Value = intPOStatusIDprListPOByCoordinatorPaged.Parameters("@UserTypeID").Value = intUserTypeIDprListPOByCoordinatorPaged.Parameters("@Archived").Value = intArchivedprListPOByCoordinatorPaged.Parameters("@PageNum").Value = intPageNumprListPOByCoordinatorPaged.Parameters("@PerPage").Value = intPerPage
SqlConnection1.Open()dr = prListPOByCoordinatorPaged.ExecuteReader(CommandBehavior.CloseConnection)
Me.Pages = prListPOByCoordinatorPaged.Parameters("@Pages").ValueMe.Rows = prListPOByCoordinatorPaged.Parameters("@Rows").Value
If Me.Rows / intPerPage > Me.Pages Then   Me.Pages = Me.Pages + 1End If
Return dr
prListPOByCoordinatorPaged.Dispose()SqlConnection1.Close()SqlConnection1.Dispose()
End Function
</code>
It does not crash, it returns my data reader with the correct records. Unfortunately my property values are returned as 0. They should have values.
Anyone know how to do this?
Thanks.

View 1 Replies View Related

Using Output From A Stored Procedure As An Output Column In The OLE DB Command Transformation

Dec 8, 2006

I am working on an OLAP modeled database.

I have a Lookup Transformation that matches the natural key of a dimension member and returns the dimension key for that member (surrogate key pipeline stuff).

I am using an OLE DB Command as the Error flow of the Lookup Transformation to insert an "Inferred Member" (new row) into a dimension table if the Lookup fails.

The OLE DB Command calls a stored procedure (dbo.InsertNewDimensionMember) that inserts the new member and returns the key of the new member (using scope_identity) as an output.

What is the syntax in the SQL Command line of the OLE DB Command Transformation to set the output of the stored procedure as an Output Column?

I know that I can 1) add a second Lookup with "Enable memory restriction" on (no caching) in the Success data flow after the OLE DB Command, 2) find the newly inserted member, and 3) Union both Lookup results together, but this is a large dimension table (several million rows) and searching for the newly inserted dimension member seems excessive, especially since I have the ID I want returned as output from the stored procedure that inserted it.

Thanks in advance for any assistance you can provide.

View 9 Replies View Related

Regression Testing A Stored Procedure That Produces Multiple Rowsets

Nov 1, 2006

How do I write a regression test for a stored proc that produces multiple rowsets via multipl e select queries? E.g.
CREATE PROCEDURE myProc AS
SELECT 'Some stuff', GETDATE()
SELECT 'Some more stuff'

For single-select procs, I can create a temp table and INSERT #temp EXEC myProc, then evaluate the contents of the table to verify correct behavior, but that doesn't work in this case.

View 1 Replies View Related

Promlem With Loging In Managment Studio

Oct 30, 2006

hi

I'm going to use Enterprise edition

when I want to log in Managment Studio I face a window asking me for Server Name in addition to Server Type and authentication mode.

what should I write in Server Name section.I know the format is:

ComputerNameInstance Name

but what should I write in Instance Name??

thanks

View 5 Replies View Related

Database Output Problem For A SQL Server 2000 Stored Procedure

Oct 27, 2006

Hi,  I have a problem with "database output"  window in executing a select-sp in vs 2005 standard. The db is a sql server 2000 one.When I execute the sp within VS, the database output correctly displays the execution information:No rows affected.(1 row(s) returned)@RETURN_VALUE = 3 but I can't see the returned rows (3 rows are returned); I only see the column names and no data.Running [dbo].[spBkm_GetList] ( @IDUser = <DEFAULT>, [.........]).IDBkm UIBkm IDUser --------------------- -------------------------------------- ---------
No rows affected. If I run the same sp in Sql Server Manager Studio Express it correctly shows the data of the 3 rows returned.  The sp uses  EXEC sp_executesql @Sql, @ParamList, ...... for executing the sql statement and the last line of sp is  RETURN @@ROWCOUNTI've tried removing the "RETURN @@ROWCOUNT" with no success.  The problem affects only one sp, the others, which are absolutely similar, work properly . I don't know what is the problem...Any idea?Thanks in advance 

View 1 Replies View Related

How To Connect To Database In SQL Sever Managment Studio

Jun 28, 2006

hi
 i have created a .aspx page and a sql database in visual studio ,, my question is how can i connect that  database in SQL Server Managment Studio?

View 3 Replies View Related

How To Setup Linked Servers With SQL Managment Studio

Dec 29, 2007

Hi Everyone,
I am using SQL Server 2005 with SQL Management Studio.
What I am trying to do is move tables and stored procedures from one database on one server to another database which is on a different server. Essentially, I am trying to move tables and stored procedures from a database on my local computer to a database on our staging server I was told the best way to do this would be to use a linked server. I have been trying to set one up using managment studio but right clicking on server-object and choosing 'new ---> Linked Server' but I have not been able to successfully create the connection.
Can anyone out there explain me to me how to setup the linked server using SQL 2005 Management Studio?
Thanks! 
 

View 3 Replies View Related

Modifying Triggers In Managment Studio Express

Oct 16, 2006

I have a database with an update trigger, which shows up under the Triggers object in the database tree. When I modify the item and try to save it it prompts me for a disk location to save the query. I then reopen the item on the db tree, and it shows the old code. What am I doing wrong?

Mike

View 3 Replies View Related

Rename A Stored Procedure In Server Management Studio

Jan 18, 2008

How do you rename a stored procedure in SQL Server Management Studio?  I tried right clicking on the stored procedure and I don't see a Rename option.

View 2 Replies View Related

SQL Server 2014 :: Insert Stored Procedure Output To Table And Add Datetimestamp

Jun 22, 2015

I have a need to insert stored procedure output a table and in addition to that add a datetimestamp column.. For example, Below is the process to get sp_who output into Table_Test table. But I want to add one additional column in Table_test table with datetimestamp when the procedure was executed.

insert into Table_Test execute sp_who

View 2 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved