Sort Displayed Multi Parameter

Jul 25, 2007

Hi all,



Is it possible to sort the values in a multi-paramter.

Notice, i'm am working with a model.

For the moment my multivalue selectionbox looks like this

B

D

H

A

C

F



And of course i would like it to be

A

B

C

D

E

F



Is there a way to do this ?



Any help is welcome.

Vinnie

View 4 Replies


ADVERTISEMENT

Want Sp Output Parameter To Be Displayed

Oct 4, 2007

Hi,
I have a sp like this:

Create PROCEDURE sp_child2 @inp int, @out int output
AS
SELECT @out = @inp * 10
GO

In the report screen i want the following:

A text box which will take the @inp(this will come automatically)
When i click the "view report" the output value should be displayed in the textbox i have in the report.

But the problem i am facing is with the above sp is its creating two text boxes automatically asking for @inp and @out.If i dont give anything in @out text box and press the view report an error is thrown asing me to fill the output box.

Isnt it supposed to be a output value?Am i doing something wrong?

please help...

View 1 Replies View Related

Reporting Services :: Multi-value Parameter Not Passing In Subreport Parameter List

Jul 29, 2015

I have two report , first is main report which is matrix and have one parameter User_ids which is multi value selection and my second report is basic chart of user_wise performance.

Now, my main report (matrix ) works fine for Multiple selection of users and i have putted one textbox on main report chart which has action properties set for chart report, when user click on chart button it must goes to chart with user selected in main report. Now , i have used expression for parameter to send it like ..

=join(parameter!user_id!value,",") which pass selected value to chart 

And when I am selecting single user it passing that value to chart parameter list but , when it is more than one user it errors with conversion failed when converting the nvarchar value '121,128' to data type int. But my chart also works when passing 121,128 in user parameter in preview of report .

View 2 Replies View Related

SSRS Toggle Parameter Between Multi-Value And Single Value Based On Another Parameter

Feb 4, 2008



I would like to be able to adjust the multi-value property of a parameter based on the value of another parameter in my report. The controlling paramter would be binary with two options for Single or Multiple selection. I would like my parameter to default to multi-value, which I can do on the screen selection. I have tried to add an IIF statement to the XML code, with no success. Any ideas would be helpful.

Thanks

View 4 Replies View Related

How To Sort A Table With A Parameter

Jan 8, 2007

I have a "Sales shipments" report with several colums. I want a parameter for the user so he choose how to sort. I have two colums in my report I want to sort on: ItemNumber and DeliveryDate.

I added a Report Parameter UserSort with two labels (and values): Item (ItemNumer) and Date (DeliveryDate).

Then I tried to set the sorting

View 6 Replies View Related

Stored Procedure With A Sort Parameter

Apr 20, 2006

I have a SQL Server 2005 Stored Procedure that takes a parameter to sort on:
-----------------------------------------------------------------
ALTER PROCEDURE [dbo].[GetAllApplications_Sorted]

@sortType varchar(25)

AS
SET NOCOUNT ON;
SELECT aev.ApplicationID,
aev.ApplicationName,
aev.EventMessage,
aev.MachineID,
aev.MachineName,
aev.EventLevel,
ellu.EventImg,
ellu.EventLevelID,
dbo.GetMaxEventLevelByApplicationID(aev.ApplicationID) AS maxEventLevel
FROM dbo.ApplicationEventView aev, dbo.EventLevelLookUp ellu
WHERE ellu.EventLevelID=dbo.GetMaxEventLevelByApplicationID(aev.ApplicationID)
AND aev.EventLevel=ellu.EventLevel
ORDER BY ellu.EventLevelID + ' ' + @sortType
-----------------------------------------------------------------
Problem is I keep getting this error:
Conversion failed when converting the varchar value 'desc' to data type int.
And I can't figure out why...
 
Thanks,
 
Doug

View 1 Replies View Related

Pass A Parameter For Sort Order

Jan 4, 2005

Is there a way to pass a parameter into a stored procedure to set the sort order.

I have tried things like

ORDER by EmployeeID @direction

where @direction is a varchar with a value of 'desc' and I get an error.

I do not want to dynamically create the sql and use sp_executesql.
I have already done it this was but I am looking for a better solution.

View 1 Replies View Related

Pass Sort Parameter In Stored Procedure

Oct 29, 2007

hi,
i searched a lot to find how to pass an orderBy parameter finally i used a case block in my code and it works now how can i add a second parameter for ascending and descending order(@sortAscOrDesc)
when i use it after the end of case statement i get error
here is my sp:CREATE PROCEDURE [userPhotos]
@userID int,@orderBy varchar(100)
ASSELECT ID,UserID,Photo,ALbumID,Title,views,date_added from userAlbumPic where userID=@userID and albumID=0 order by
case @orderBy
when 'date_added' then date_added
when 'views' then [views]
else date_added
end
GO

View 7 Replies View Related

Sort Order Via Parameter-now Security Issue

Mar 19, 2007

we are firing this from my asp page, what i can't work out how to do is pass a sort order via parameter to my stored procedure.
Any Help appreciated

Nigel

set conn = CreateObject("ADODB.Connection")

conn.open MM_fc_conn_STRING

sql = "EXEC Sproc_01020_Select_WebUser" & " @UserLoginName='" & Request.Form("Username") & "'"

set Recordset1 = conn.execute(sql)

View 17 Replies View Related

Sort Expression As Store Procedure Parameter?

Jul 23, 2005

Can I pass a sort expression into a store procedure as a parameter? Iwant to do sth like the following but do not know if it's possible.Maybe I need some tricks to work around?CREATE Procedure SelectAllRoles(@SortExpression varchar(20))ASIF @SortExpression <> ''THENSELECT Id, Name, Name2, LastUpdatedFROM [Role]ORDER BY @SortExpressionELSESELECT Id, Name, Name2, LastUpdatedFROM [Role]GOThanks!Zhu Ming

View 1 Replies View Related

Stored Procedure Sort Parameter Doesnt Work

Jul 22, 2006

Hello, I am trying to make this.

CREATE PROCEDURE [dbo].[P_SEL_ALLPERSONAS]

@nmpersona int,

@sortorder varchar(20)



AS

BEGIN

select nmpersona, dsprimernombre, dssegundonombre,

dsprimerapellido, dssegundoapellido

from personas

order by @sortorder

END



But I got this error. Please help



Msg 1008, Level 16, State 1, Procedure P_SEL_ALLPERSONAS, Line 13

The SELECT item identified by the ORDER BY number 1 contains a variable as part of the expression identifying a column position. Variables are only allowed when ordering by an expression referencing a column name.

View 5 Replies View Related

Multi Value Parameter

Jan 16, 2007

Hi,

In my report i have a multi valued parameter, when i view my report in the Web application with Report Viewer, The multi valued parameter is displaying in light color.Can we able to change this.

Thanks in advance

View 2 Replies View Related

Multi-Value Parameter

Sep 5, 2007

I have a stored procedure im passing into Reporting Services. Only problem is , What do i need to change to allow the user to select more then one value. I already know what to do on the reporting services side, but it keeps erroring with the data source IE my stored procedure. Here's the code:




Code Snippet
SE [RC_STAT]
GO
/****** Object: StoredProcedure [dbo].[PROC_RPT_EXPENSE_DETAIL_DRILLDOWN_COPY] Script Date: 09/05/2007 13:49:09 ******/
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
ALTER PROCEDURE [dbo].[PROC_RPT_EXPENSE_DETAIL_DRILLDOWN_COPY]
(@Region int = Null)
AS
BEGIN
SELECT Budget_Reporting_Detail.Budget_Report_Detail_Datetime, Budget_Reporting_Detail.Budget_Report_Detail_Document_Type,
Budget_Reporting_Detail.Budget_Report_Detail_Code, Budget_Reporting_Detail.Budget_Report_Detail_Description,
ISNULL(Budget_Reporting_Detail.Budget_Report_Detail_Amount, 0) AS Actual, Budget_Reporting_Detail.Budget_Report_Detail_Qty,
Budget_Reporting_Detail.Budget_Report_Detail_Responsible, Territory.Name+'('+Code+')' as [Name], Region.Region, Round((Forecast.Budget_Amount/13),2) AS Budget,
Forecast.Budget_Type_Code, Forecast.Budget_Year, Budget_Forecast_Period,
Forecast.SalesPerson_Purchaser_Code
FROM RC_DWDB_INSTANCE_1.dbo.Tbl_Budget_Reporting_Detail AS Budget_Reporting_Detail RIGHT OUTER JOIN
RC_DWDB_INSTANCE_1.dbo.Region AS Region RIGHT OUTER JOIN
(SELECT Budget_Type_Code, Budget_Year, SalesPerson_Purchaser_Code, Budget_Amount
FROM RC_DWDB_INSTANCE_1.dbo.Tbl_Budget
) AS Forecast INNER JOIN
RC_DWDB_INSTANCE_1.dbo.Territory AS Territory INNER JOIN
RC_DWDB_INSTANCE_1.dbo.Tbl_Territory_In_Sales_Responsible AS Territory_In_Sales_Responsible ON
Territory.Code = Territory_In_Sales_Responsible.Territory_Code INNER JOIN
RC_DWDB_INSTANCE_1.dbo.Tbl_Territory_In_Region AS Territory_In_Region ON Territory_In_Region.Territory_Code = Territory.Code ON
Forecast.SalesPerson_Purchaser_Code = Territory_In_Sales_Responsible.SalesPerson_Purchaser_Code ON
Region.Region_Key = Territory_In_Region.Region_Key ON Budget_Reporting_Detail.Budget_Type_Code = Forecast.Budget_Type_Code AND
Budget_Reporting_Detail.Budget_Year = Forecast.Budget_Year AND
Budget_Reporting_Detail.SalesPerson_Purchaser_Code = Forecast.SalesPerson_Purchaser_Code
WHERE (Region.Region_Key IN( @Region)) AND (Forecast.Budget_Year = 2007)



END




what am i doing wrong?

View 1 Replies View Related

Multi-value Parameter

Jan 15, 2008



Hi:
I am building a report and have a few parameters. One of this parameters is set up as Multi-Value. When I only select one value everything is running fine. But when I select multi values I get an error saying I must declare my variable.

Any idea why this is happening?

Ben

View 3 Replies View Related

Multi Value Parameter

Sep 3, 2007

hi,
i read from this forum that to pass array to report is using multi value parameter . my problem now is
1. can i pass multi dimension array.
2. how do i show the multi value parameter in a table . for example i have a multi value parameter that may contain 10 or 20 array . how do i dynamic it show in table.

rgds,
charles

View 1 Replies View Related

Help With Sproc And Multi Parameter

Dec 11, 2006

I'm trying to build a sproc that will return rows even if some of the parameters are blank. For example; if a user does not enter a priority, a status, or a caller the sproce should still return rows based on the other parameters.
 Can anyone help me find a way to modify my sproc bellow to allow this? I think the way I have it  bellow will only return those rows where the user has entered a parameter or the record has a null in the field.ALTER PROCEDURE dbo.ContactManagementAction

(
@ClientID int,
@Priority int,
@TStart datetime,
@TEnd datetime,
@Status nvarchar,
@ConTypeID int,
@Caller nvarchar,
@Keyword nvarchar
)

AS
SELECT Task_ID, ClientID, Priority, ActionDate, Subject, Note, Status, CompletionDate, TaskDocument, ReminderDate, Reminder, ReminderTime, Sol_ID,
DateEntered, EnteredBy, Caller, ContactTypeID, DueDate
FROM tblTasks
WHERE (ClientID = @ClientID) AND (Priority = @Priority) OR (Priority IS NULL) AND (ActionDate BETWEEN @TStart AND @TEnd) AND (Status = @Status) OR (Status IS NULL) AND
(ContactTypeID = @ConTypeID) OR (ContactTypeID IS NULL) AND (Caller = @Caller) OR (Caller IS NULL) AND (Subject LIKE @Keyword) OR (Subject IS NULL)

RETURN 

View 15 Replies View Related

Multi Parameter AND Statement

May 27, 2008

Is it possible for an AND statement to take mulitple parameters? See below code:

SELECT tblQuestion.Question, tblAnswer.Answer

FROM (tblAnswer INNER JOIN tblQuestion ON tblAnswer.QuestionID = tblQuestion.ID)

WHERE (tblAnswer.StateID = ?) AND (tblAnswer.QuestionID = 14)

Is something like this possible?:
AND (tblAnswer.QuestionID = 14, 26)

Thanks

View 2 Replies View Related

Multi-value Parameter Calculation

Jun 23, 2007



OK Guys....



If you answer this one, you will save my life...and you WILL be the MAN or WOMAN!!!!



Problem: I have a set of 24 matrix's that need to calculate the difference between the last two years and display in a field to the right of the last rendered column. Since I have been struggling with this, let's just assume there is no better way than how I currently have it set up. (one table that does the calculations for me and I set one field on the report to display the most recent two columns difference in my report)



what I can not figure out is: when I choose one of my parameters the report displays the information I want...but when I choose more than one...well there is the problem....



In order to obtain the most help for myself I will ask this in the most general way possible so as not to get bogged down into my specific solution...



Desired Result: How to pass all my parameter values from my multi-value parameter during runtime to a SQL Stored proc from my dataset within Reporting Services at runtime, Match the parameter to the field, get the result and store it in a variable, then do it again and add the second to the first within the variable, and so on and so on , until all of the parameters are used. Then sum the values and display in a field.



HELP, HELP, HELP Please....

View 3 Replies View Related

Allow Null Value In Multi-value Parameter

Jun 28, 2007

Hello,



I have a multi-value parameter field and each item comes from a table in the DB.

This multi-value parameter allows to select all or some of the items.

What if I don't want to select ANY item??



I read in the forum the several tray to do the same but the answers are not so clear..



If I say that at the end is a bug in SSRS... AM I right?



Thank you



Marina B.

View 1 Replies View Related

Empty Multi-value Parameter

Apr 24, 2007

Several people have asked about this, but I have not seen a response that works. I have several parameters that I want to use as filters. If a particular filter parameter is not entered, the report should not apply a filter on that criterion. It works fine to create a single value parameter which allows null, and use the following in SQL:

WHERE ( [Field1] = @Field1_Filter OR @Field1_Filter IS NULL )


How can the same effect be achieved for a multi-value parameter? If you try to create a multi-value parameter which allows null, the report builder gives an error. I can't use "allow blank value" because some of my parameters are integer parameters. Without the allow null, the report generator requires me to enter at least one value. So I don't know how you can get a value of "not entered" into a multi-value parameter.

I also don't know how you would check for the "not entered". Someone suggested the following SQL:

WHERE ( [Field1] IN (@Field1_Filter) OR @Field1_Filter IS NULL )

This generates an error when generating the report if multiple values are entered for the parameter (the normal condition). The error is " An expression of non-boolean type specified in a context where a condition is expected, near ',' ".

How is this supposed to be done?

Thanks for any insight

View 12 Replies View Related

Multi Value Parameter In Db2 Query

Mar 19, 2007

hi,

i'm trying to perform a query against a db2 database like this:

SELECT ... FROM ... WHERE (field IN (?))

Then i let reporting services pass the parameter to the report. When i try to preview the report, i get the following error:

An error occurred during local report processing,
An error has occured during report processing,
Cannot add multi value query parameter '?' for data set ... because it is not supported by the data extension

But when i type the query like this

SELECT ... FROM ... WHERE (field IN ('value1','value2'))

it executes flawlessly.

I am using the IBM ole db driver for db2 if that matters

Can anyone help me?

View 5 Replies View Related

Multi Value Report Parameter

Feb 1, 2007

HI there.

I have been working on this for quite some time and I can not figure out what I am doing wrong.
I have a report filter called ItemFilter and I have declared as a report parameter where the multi value checkbox is checked. The values from this filter are coming from the item table.
SO the users drilldown on the filter when they run the report an select the Items that they would like to display info for. I had the following code before in the where

where
([CRONUS International Ltd_$Item].No_ = @itemfilter). This only worked if they selected on item from the list.

I want them to be able to select multiple Items or all. The code above did not work because there were commas separating one item from the other and I was getting an error.

I changed to

whrere

([CRONUS International Ltd_$Item].No_ IN (@itemfilter)).

Now this only returns the first item that I enter on my Itemfilter parameter.

Does anyone have any clue in regards to this ?? I am sure I am using the wrong syntax, but I do not know what to change it too.



Thanks






View 1 Replies View Related

Multi-Value Parameter Width

Mar 27, 2007

Good afternoon,

I've designed a Reporting Services report that has a multi-value parameter. The report works just great. The only issue I'm running into is that the users are complaining that when they want to select the values, within the multi-value parameter box, they have to scroll it to the sides way too much. This also makes them select values by mistake.



Is there away to inscrease the width of the multi-value parameter box?



Best regards.

View 20 Replies View Related

Multi-Value Parameter And FireFox

Jul 6, 2007

I am experiencing a problem with the multi-value parameter dropdown in the ReportViewer when using FireFox, but in IE it seems to work fine. The symptom is when I click on the dropdown the list of options appears and then quickly disappears before I can select anything and I only experience the problem with multi-value parameters. I also have noticed that the dropdown is grayed out but I can still click it. Also, the position of the dropdown options are different in FireFox (pushed all the way to the left). I have created a very basic example at https://www.register4this.com/testreport.aspx to demonstrate the problem. There is no report, only the single "Orgs" parameter to keep things as simple as possible.



I suspect that I am missing something obvious because I haven't been able to find anyone else reporting this issue so any help would be appreciated. My ReportView control is configured as follows:




Code Snippet

<rsweb:ReportViewer ID="ReportViewer1" runat="server" AsyncRendering="False" Font-Names="Verdana" Font-Size="8pt" Height="400px" ProcessingMode="Remote" Width="400px">

<ServerReport ReportPath="/REG_Report/testreport" ReportServerUrl="http://reports.register4this.com/reportserver" />

</< FONT>rsweb:ReportViewer>



The report code is as follows:






Code Snippet

<?xml version="1.0" encoding="utf-8"?>

<Report xmlns="http://schemas.microsoft.com/sqlserver/reporting/2005/01/reportdefinition" xmlns:rd="http://schemas.microsoft.com/SQLServer/reporting/reportdesigner">

<DataSources>

<DataSource Name="Members">

<DataSourceReference>Members</DataSourceReference>

<rd:DataSourceID>54f7f4de-9fe5-44e9-bcf0-467d024725cb</rd:DataSourceID>

</DataSource>

</DataSources>

<BottomMargin>1in</BottomMargin>

<RightMargin>1in</RightMargin>

<ReportParameters>

<ReportParameter Name="Organizations2">

<DataType>String</DataType>

<Prompt>Orgs:</Prompt>

<ValidValues>

<DataSetReference>

<DataSetName>Organizations</DataSetName>

<ValueField>orgID</ValueField>

<LabelField>orgName</LabelField>

</DataSetReference>

</ValidValues>

<MultiValue>true</MultiValue>

</ReportParameter>

</ReportParameters>

<rd:DrawGrid>true</rd:DrawGrid>

<InteractiveWidth>8.5in</InteractiveWidth>

<rd:SnapToGrid>true</rd:SnapToGrid>

<Body>

<Height>2in</Height>

</Body>

<rd:ReportID>504c91c0-4beb-421e-bae0-4d581303b3e2</rd:ReportID>

<LeftMargin>1in</LeftMargin>

<DataSets>

<DataSet Name="Organizations">

<Query>

<CommandType>StoredProcedure</CommandType>

<CommandText>REG_spGetOrganizations_org</CommandText>

<QueryParameters>

<QueryParameter Name="@orgID">

<Value>=System.DBNull.Value</Value>

</QueryParameter>

</QueryParameters>

<DataSourceName>Members</DataSourceName>

</Query>

<Fields>

<Field Name="orgID">

<rd:TypeName>System.Int32</rd:TypeName>

<DataField>orgID</DataField>

</Field>

<Field Name="orgName">

<rd:TypeName>System.String</rd:TypeName>

<DataField>orgName</DataField>

</Field>

</Fields>

</DataSet>

</DataSets>

<Width>6.5in</Width>

<InteractiveHeight>11in</InteractiveHeight>

<Language>en-US</Language>

<TopMargin>1in</TopMargin>

</Report>





Any help wpuld be greatly appreciated.

View 10 Replies View Related

Pass Multi Value As Parameter

Jun 1, 2007

Hi All,

Is it possible to pass a multi value parameter from one report to another using the "jump to report" feature?

ie;



I have report A that has a mutli value parameter (para1). This report has a link with the action property set to jump to another report(Report B). Report B requires the same multivalue parameter. I have tries setting the parameter in the interface as well as trying the join function. Nothing seems to pass the values correctly.



regards

View 3 Replies View Related

How Can I Print A Multi-value Parameter

Jul 29, 2005

I have a multi-value parameter and I need to print its value in report.

View 4 Replies View Related

Multi-value Parameter And Function

Mar 21, 2008

I have a report with the following dataset query:



Code Snippet
SELECT ...,
dbo.getActivitySinceBeginningYear(..., @countryId ,...) AS HoursYear
FROM ....
WHERE cast(detail.COUNTRY_ID as nvarchar(max)) IN (@countryId)
AND ...
GROUP BY ...




countryId is defined as a String multi-valued parameter.
The getActivitySinceBeginningYear is defined as follows:




Code Snippet
ALTER FUNCTION dbo.getActivitySinceBeginningYear
(
...
@countryId ntext,
...
)
RETURNS decimal(18,5)
AS
BEGIN
declare @return decimal(18,5)
set @return = 0.0

SELECT @return = SUM(detail.HOURS_WORKED)
FROM ...
inner join charlist_to_table(@countryId, Default) f on detail.COUNTRY_ID = f.str
WHERE ...
RETURN @return
END


This function works as expected if I transmit one ID or several.
The report works fine if I check only one ID.
If I check several IDs, the report displays this error:
Procedure or function dbo.getActivitySinceBeginningYear has too many arguments specified.

Why???

My second problem is with the Where clause:



Code Snippet
WHERE cast(detail.COUNTRY_ID as nvarchar(max)) IN (@countryId)


If I do:



Code SnippetWHERE detail.COUNTRY_ID IN (@countryId)


I have the following error:
Conversion failed when converting the nvarchar value '3,5' to data type int.
(I transmitted 3 and 5 for countryId)

That's why I tried to use a cast, but the data returned by the query is wrong when I transmit several value.
??

View 7 Replies View Related

Multi Value Integer Parameter

Jul 11, 2007

I am trying to create a report with a multi value integer parameter. I have tried



="SELECT * FROM vProjectRequestStatus WHERE ProjectRequestStatusCode IN (" + Parameters!StatusCode.Value + ")"



I get an error stating



An error occurred during local report processing.

An error has occurred during report processing.

Cannot set the command text for data set 'ProjectRequestStatus'.

Error during processing of the CommandText expression of dataset 'ProjectRequestStatus'.



Has anybody worked with integers?



Thanks,



Fred

View 8 Replies View Related

Reporting Services :: Page Break Based On Sort Parameter Value In SSRS 2008

Nov 19, 2015

I have a SSRS report with data in below format.

ID       Name    Date
1           A         null
2           B        01/01/2012
3           C        01/02/2013

Also, I have a sort parameter @sort and values are (Name, ID, Date)

I want to apply page break whenever @sort=Name. There should be no page break when user selects @sort = ID or Date. Page break should happen only when @sort value = Name

it should be like this...

Page 1:
ID       Name    Date
1           A         null
Page 2:
ID       Name    Date
2          B         01/01/2012
Page 3:
ID       Name    Date
3           C        01/02/2013

I need achieving the above task.

View 2 Replies View Related

In Keyword And Multi Value In Single Parameter

Aug 29, 2007

Hello
I created a table adapter with the following query
select * from building where buildingname in (@param1)
I used the query builder to the test the query and it works ok if I pass a single value
ex: name: @param1     value: Building1
but when I use the value: Building1, Building2 then it doesn't return anything
If i do a direct sql: select * from building where buildingname in ('Buiding1','Buiding2') returns many rows.
Now I have a class that has the following function<System.ComponentModel.DataObjectMethodAttribute(ComponentModel.DataObjectMethodType.Select, False)> _
Public Function getBuilding(ByVal building As String) As myDataSet.buildingDataTableReturn adapter.getBuilding(building)
End Function
When I call this function I try to pass the building value sorta like
dim building as string = 'Building1,Building2'
and it doesn't work.  I tried a whole bunch of variations. 
How are you supposed to format the parameter string?
Thanks
Peter 
 
 

View 4 Replies View Related

Display Multi Value Parameter LABEL

Mar 6, 2007

Hello.
I have a multi value parameter in my report.
I want to know how can I display all of the selected values in this parameter in a text box.
Whan I try to use this parameter in a textBox it automaticly take the value:
Parameter.param.Value(0) Whice take only the first select value.

Is there a simple way of doing it?

Thanks.

View 1 Replies View Related

Report Parameter And Multi Value Prompt

Sep 21, 2007

Hi all

Basically I had 2 paramater which ComputerName and MemberName.

The membername was set as Multi-Value as sets as follow:
Label: Value:
Exclude Domain Admins Domain Admins
Exclude Local Install Local Install

And the query is:

SELECT id,
ComputerName,
GroupName,
MemberName,
ScanDate
FROM GROUPMEMBERS WITH (NOLOCK)
WHERE ComputerCN LIKE '%' + @ComputerName + '%'
AND MemberName NOT IN (@MemberName)
ORDER BY ComputerName ASC

The prompt is like this:
Computer Name [ ] Excluded by [ ]

The issue is in the second prompt I have to select
"something" which is I don't want to. I want the user to have this parameter as an optional.

Any ideas?

Thanks

View 2 Replies View Related

How To Passing Multi Value Parameter In SQL Query

Jul 23, 2005

I have a query :Exec 'Select * From Receiving Where Code In (' + @pCode + ')'@pCode will contain more than one string parameter, eg : A1, A2, A3How can i write that parameters, I try use :set @pCode='A1','A2','A3'but get an error : Incorrect syntax near ','Please help meThanks

View 10 Replies View Related







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