Solved

SUPPRESS RESULT SET FROM A STORED PROCEDURE

Posted on 2008-10-16
1
1,768 Views
Last Modified: 2008-12-12
Is it possible to suppress a resultset from a stored procedure?

See Code Snippet for example..

I'd like to call MONTHLYREPCOMMISSIONS  and return only the results from the third stored procedure "SalesTracingNdcMainReportByRepSP".

Thanks!
ALTER              PROCEDURE dbo.MONTHLYREPCOMMISSIONS 
@Year int,
@Period int,
@Rep varchar(10)
AS
DECLARE @SQL NVARCHAR(4000)
DECLARE @ParameterList nvarchar(200)
DECLARE @ParameterList2 nvarchar(200)
 
EXEC OutOfTerritorySP @Year,@Period,'0'
EXEC FSDBMR.dbo.SalesTracingCommissionInvoiceDetailReportSP @Year,@Period
EXEC SalesTracingNdcMainReportByRepSP @Year,@Period,0
 
GO
SET QUOTED_IDENTIFIER OFF 
GO
SET ANSI_NULLS ON 
GO

Open in new window

0
Comment
Question by:DEADSETONFINISHING
1 Comment
 
LVL 142

Accepted Solution

by:
Guy Hengel [angelIII / a3] earned 250 total points
ID: 22733208
>Is it possible to suppress a resultset from a stored procedure?
no.
only the "x rows affected" can be supressed with the SET NOCOUNT ON

anything else needs to be programmed into the "other" procedures, a parameter to say "don't return anything, just do your work.
0

Featured Post

PRTG Network Monitor: Intuitive Network Monitoring

Network Monitoring is essential to ensure that computer systems and network devices are running. Use PRTG to monitor LANs, servers, websites, applications and devices, bandwidth, virtual environments, remote systems, IoT, and many more. PRTG is easy to set up & use.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Refresh Dev server with Production database 8 29
SQL Help 27 45
Inserting oldest record into new table. 5 25
Loops and updating in SQL Query 9 30
Why is this different from all of the other step by step guides?  Because I make a living as a DBA and not as a writer and I lived through this experience. Defining the name: When I talk to people they say different names on this subject stuff l…
Hello, In my precious Article  (http://www.experts-exchange.com/Database/Reporting/A_15280-Create-Project-in-Microstrategy-Part-I.html)we saw the Configuration part for Microstrategy which included Metadata Creation and DataSource Preparation as …
Via a live example combined with referencing Books Online, show some of the information that can be extracted from the Catalog Views in SQL Server.
Via a live example, show how to shrink a transaction log file down to a reasonable size.

809 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question