cancel
Showing results for 
Search instead for 
Did you mean: 

Parameter Multiplevalues/Ranges display in crystal report

Former Member
0 Kudos

Hi All,

I have developed a crystal report, in which i have a refrence with SAP BW query as source. I have a parameter called company code(0cop_code in BW) from the bw which has the following options below.

multiple values - true

discrete values- true

ranges - true

I need to display this parameter values in the crystal report Header. I could do join formula, minimum and maximum formula if i have either multiple values as true or ranges as true. I could not display ranges and multiple values.As the values returned is not a string, i am trying to convert that to text by TOTEXT(). I am getting an error saying number,boolean, amount,string required here.Dont we have a option to overcome and display the parameter values in the crystal report header.Can you please suggest.

Thanks & Regards,

Magesh anandan.

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Magesh Anandan

This problem, ( error saying number,boolean, amount,string required ) tells me either

you are mixing field types in your if-then-else formula - when you have multiple tests in a formula, the result for all tests must be the same type of field, either all text, all numbers, etc.,

or

you are missing something in your formula, probably a quote.

If you post the exact formula here and we can look at it.

Debi

Former Member
0 Kudos

Hi debi,

Thanks for your response. Please find the formula here . join(totext({?[ZAUTCCDE]}),"") . Thanks.

Thanks & Regards,

Magesh anandan.

Former Member
0 Kudos

Hi debi,

> Thanks for your response. Please find the formula here . join(totext({?[ZAUTCCDE]}),"") . Thanks.

>

> Thanks & Regards,

> Magesh anandan.

try setting {?[ZAUTCCDE]} to be a text field and see if it still complains

Former Member
0 Kudos

Hi Debi,

We cant set this, as this parameter comes from the BW report variable. This is the company code variable in BW. Please let me know if i can do anything further above this. Thanks.

Thanks & Regards,

Magesh anandan.

Former Member
0 Kudos

You can not use range parameters with the Join() function. Turn off the ranges = true and it should work.

Ian

Former Member
0 Kudos

You are mixing data types and this could be the source of the error complaint, although I have never used the JOIN function.

Does Crystal consider a parameter to be an array? Can JOIN even be used with a parameter list? Try it in a test report where you are entering text in the parameter.

Former Member
0 Kudos

Hi Ian,

Thanks for the reply . These parameter conditions cannot be changed at the crystal report level, as it reflects from the BW query. This variable is a select options variable, so both ranges and multiple values will be enabled as true. Is there any other way to display the parameter in the header ?

Hi Debi,

This is a select option paremeter, so the parameter will be of type array. Do you think anyother way to populate this,both ranges and multiple values.

Thanks & Regards,

Magesh Anandan.

Former Member
0 Kudos

If Ian says Join can not be used with a parameter then you can't do it.

II have no experiance with arrays. Ian, is there a way to feed the parameter values into an array in the report?

Debi

Former Member
0 Kudos

A multiple value parameter is an Array, so join() can be used with such parameters. Have a range withing the parameter is wht is causing the problem.

Never tried to display such a mixed parameter so have no idea as to how you would go about it. Normally with a standard range parameter two formula would return limits

minimum(?rangeparam)

maximum(?rangeparam)

Ian

Former Member
0 Kudos

Agreed, a parameter with multiple values is an array, but it seems crystal does not see it that way with regards to the Join function.

Can the parameter data be used in a formula as input for an array and then use the join function on the formula to display it?

Magesh, Take a look at the function MakeArray() and see if you can make it work for you.

Edited by: Debi Herbert on May 12, 2011 12:22 PM :

Is your parameter a range? or Does it simply accept multiple values?

Answers (0)