If you are unable to create a new account, please email support@bspsoftware.com

 

News:

MetaManager - Administrative Tools for IBM Cognos
Pricing starting at $2,100
Download Now    Learn More

Main Menu

Select and Search promt

Started by priya@90, 04 Mar 2016 06:53:07 AM

Previous topic - Next topic

priya@90

Hi,

How to search with emp_id and emp_name in Select and search prompt. If users wants to search with Name, should display name and if they search with ID, that should display. How to achieve this functionality.

I am giving use value:emp id and display value is:emp id. Can i get any solution.
I tried union but it's taking long time and finally error was showing timeout

Thanks,
Priya


Lynn

Quote from: priya@90 on 04 Mar 2016 06:53:07 AM
Hi,

How to search with emp_id and emp_name in Select and search prompt. If users wants to search with Name, should display name and if they search with ID, that should display. How to achieve this functionality.

I am giving use value:emp id and display value is:emp id. Can i get any solution.
I tried union but it's taking long time and finally error was showing timeout

Thanks,
Priya

Create a data item in your query that feeds the prompt control that contains the concatenation of name and ID, perhaps like this:
John Doe (1234)

Set this data item as the display value. Set the ID as the use value.

Have the users open the Options link on the prompt control and select the option "Contains any of these keywords".

priya@90

Thank You Very for your help and it's working as expected but little bit slow(1min:20sec). I think we can manage


priya@90

one more issue i have in the same prompt and this is mandatory prompt when user's click on 'Search' in the this prompt with out giving any value, i have to show 'Alert Message' says 'Please select a Value'. I think this will work with JS as per my knowledge. I don't find proper JS in google. can you provide if anybody done this. Please find the attachment.

Thanks,
Priya

Lynn

Why not just include an instruction above the prompt control? I think judicious use of Java Script is wise.

navissar

I have to say this is the sort of place where I wouldn't mind a script in general, although in this case it is just redundant.
An instruction on the screen is "Objects in the mirror" - it's a space consuming line that you only ever need once. And a script wouldn't affect any important functionality - the worse thing that can happen in this case is that it won't alert the user.
However, in this particular case it is also redundant. I don't think report developers should cater for a situation where the user clicks "Search" with an empty box. Nothing will come back for the search, which is really what the user asked for.

priya@90

What solution i can  provide to user, whether solution is there for this kind of requirement, Can i say not possible and not sure how to convenience him with my less experience. Please suggest how to do this

Thanks,

navissar

Ah, "The User", that mythical, frightening creature. Part child, part dragon, part drone, he is stubborn, unexpected, scary and will only have things that way and that's that.
I think by and large the problem here is to be solved with soft skills rather than technical skills. On one hand, you could write a convoluted solution that will involve a script invoked every time the search box is focused and you will have to maintain moving from version to version. That script will have to be then deployed to any other report using S&S prompt because, well, you already did it once, so why not. It'll take you about three days to write, or you can bring in a specialist to write it and pay them for a day's work. And of course with upgrades it might break, so there's this additional cost.
Or, on the other hand, you could talk to your business point of contact. You could assume the position you were hired for: a professional expert, who doesn't just deliver requirements but actually comments on these requirements to make them better. You explain the cost of the change. You explain why the change is unnecessary. You explain that the behaviour as it is, that when searching for nothing we're getting back nothing, isn't a problem that needs solving but rather a very reasonable behaviour. You state your case confidently and clearly with all the authority of an expert - because you ARE an expert, and you know more about Cognos development than the business user, that's why they hired you.

It might be the case that after hearing your case, your customer will decide to do it anyway. That's fine, it's their money to waste. But in my humble opinion, your job is to make sure that it is THEIR choice, and that they understand what that choice means. 

priya@90

I have given simple solution to them and they are happy with that. I have given in text as *(Mandatory Selection) in red color. that's it.

Thanks,