Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello Again,
I am trying to create a field that will display selections from 2 other loaded fields [Prim Diag] and [Sec Diag]. If this were a report ran in Crystal the logic would be to include info for Diag Code X01.13 where listed in [Prim Diag] or [Sec Diag]. With the current table I have in QV it is possible to get this info by setting 2 separate filters (obviously), but for user ease I would like to be done with 1 step. Does anyone know how to do this? Please let me know if you need an example or attachment.
Thank you,
EK
pl attach sample application
Right so here if my end user wanted to find all accts for V42.7 they would need to search the code in [Prim Diag] to find accts 5000-5003. Then they would need to search the code in [Sec Diag] to find accts 5005-5007. I would like a way where the can search for this code once and return all valid accts. Hence my thought of using an OR function..
Somebody might come up with a better method than this, but here goes (I can't modify your example tonight as I'm not near a pc).
Create a data island in your data model that is a field containing the distinct values from both [prim diag] and [sec diag]. Use this field in your front end for the user to select against.
Then, in your chart you need to use a set analysis expression that implies an OR.
Lets assume you want sum of sales in your chart, your expression would be:
Sum({$<[prim diag]={[selected field name]}>}sales)+
Sum({$<[sec diag]={[selected field name]}>}sales)
The syntax here might not be precise as I can't check it but if you can't make it work drop a reply in and I'll take a look in the morning.
Good luck
USe:
=
[Sec Diag] &'--'& [Prim Diag]Although a concatenation would include the code in a search I need it to display only that diag code. I could concatenate and rename the tables to include both options but that is would take a lot of reloading of all my files. An if or function should be able to grab the right data I just havn't seen an example I can use.
See attached qvw.
Ahh beautiful! Thank you so much!!