J
jeremy p.
Not sure the title or my explanation will be clear, but I'll try my best.
I have a query that has two nested Iif expressions within it. The expressions compare answers from a large table that holds answers from two different forms (Individual and Entity). The forms themselves provide similar answers based on different requirements.
So in my query I have Expr1 and Expr2.
I can display the results in the query in two columns without a problem.
What I would like to do is, in the same query, have a single column that combines these answers, using a third If expression, and not show the results of the first two:
i.e., ExprTotal: Iif([Expr1]<> " ", [Expr1],[Expr2])
I know I can run Expr1 and Expr2 in a 2nd query and bring the results in, but I'd like to have it all in the same query if possible.
I'm looking into doing Expr1 and Expr2 within a subquery of ExprTotal, but not sure if this would work.
Any ideas?
(Sorry for not including the code to Expr1 and Expr2. They're very lenghty and all in shorthand, but I know they work correctly. Just can't figure out how to join them)
Thanks in advance.
EggHeadCafe - Software Developer Portal of Choice
..NET Setup Deployment - MSI, Cassini, SQL Server, NTFS
http://www.eggheadcafe.com/tutorial...5ab-35ca33da0f65/net-setup-deployment--m.aspx
I have a query that has two nested Iif expressions within it. The expressions compare answers from a large table that holds answers from two different forms (Individual and Entity). The forms themselves provide similar answers based on different requirements.
So in my query I have Expr1 and Expr2.
I can display the results in the query in two columns without a problem.
What I would like to do is, in the same query, have a single column that combines these answers, using a third If expression, and not show the results of the first two:
i.e., ExprTotal: Iif([Expr1]<> " ", [Expr1],[Expr2])
I know I can run Expr1 and Expr2 in a 2nd query and bring the results in, but I'd like to have it all in the same query if possible.
I'm looking into doing Expr1 and Expr2 within a subquery of ExprTotal, but not sure if this would work.
Any ideas?
(Sorry for not including the code to Expr1 and Expr2. They're very lenghty and all in shorthand, but I know they work correctly. Just can't figure out how to join them)
Thanks in advance.
EggHeadCafe - Software Developer Portal of Choice
..NET Setup Deployment - MSI, Cassini, SQL Server, NTFS
http://www.eggheadcafe.com/tutorial...5ab-35ca33da0f65/net-setup-deployment--m.aspx