Query help

  • Thread starter Thread starter Pat_RI
  • Start date Start date
P

Pat_RI

I have a table with 20 columns and I am looking to add a column that
searches the other 20 columns and if all the cells in that row are null
enter value in the new column =X and if there is information in any of the
other columns make new column's row value = is null? Any help would be
appreciated.

A B C D NEWCOLUMN

1 A
Z B
X
Q
X
 
It is rarely necessary to store "calculated" data, and there are some good
reasons not to.

What you are asking for sounds like something you'd be able to do in a
query.

By the way, if the "newcolumn" is an indicator that columns A-T are all
Null, why would you want a Null value in that newcolumn to represent that at
least one column (A-T) is NOT null?

By the way, #2, to the human eye, a Null and a zero-length string ("")
appear to be the same. If one of those columns ever had a value, and if the
table definition allows zls, you could have a row that appears to be all
Nulls but would NOT trigger your newcolumn.

You've described "how" you want to accomplish something, but not much about
the "why" and "what". What will having an indicator of the "Null-ness" of a
record allow you to do?

Good luck!

--
Regards

Jeff Boyce
www.InformationFutures.net

Microsoft Office/Access MVP


Microsoft IT Academy Program Mentor
http://microsoftitacademy.com/
 
Sorry about that I meant to say I want to create a query that will return
the new column. What I want to do is return any row from a table that has
over 30000 that has information in it between column C and column AF.
 
How about the following using the following expression

IIF([A] & & [C] & [D] Is Null, "X",Null)



--
John Spencer
Access MVP 2002-2005, 2007-2008
Center for Health Program Development and Management
University of Maryland Baltimore County
..
 
Back
Top