AND Expression

mardimus

New Member
Joined
Feb 2, 2015
Messages
21
I am trying to create an expression that lists a value in a new column based on the logic that a date has passed today. Any help on how to recreate this as the Today or AND expression is not working.

Was Project Delinquent?:=IIF(AND(IsNull(Date1),[Date2]<TODAY()),1,0)

Thanks for any help.

Marty
 

Excel Facts

How to total the visible cells?
From the first blank cell below a filtered data set, press Alt+=. Instead of SUM, you will get SUBTOTAL(9,)
The syntax in Access is slightly different from Excel. try this: =IIF(IsNull(Date1) and IsNull(Date2)
 
Upvote 0
Thanks for the info. I will try it. Also, my expression/function statement was cut off. Here is an updated one: =IIF(And(IsNull([DATE1]),[DATE2]<Today()),1,0)


The syntax in Access is slightly different from Excel. try this: =IIF(IsNull(Date1) and IsNull(Date2)
 
Upvote 0
This is close but not there yet. Was Project Delinquent?:=IIF(IsNull(Date1) and IsNull(Date2)<Today()),1,0).

Thoughts?
 
Upvote 0
Your first argument does not make sense:
Code:
[COLOR=#333333]IsNull(Act RFU) and IsNull(Updated RFU) < Today ()[/COLOR]
IsNull returns True or False (is the value Null or not?), so I am not sure why you are trying to compare True/False values to Today().

Can you explain exactly what it is you are trying to do here?
 
Upvote 0
The logic (in excel) is: IF(AND(ISBLANK([@[Act RFU]]),[@[Comp RFU]] < TODAY()),1,0)

It basically states that if one of the fields is blank then use the other field and is the date greater than today, if so then assign it a value.

I need to convert this to an expression in access.



Your first argument does not make sense:
Code:
[COLOR=#333333]IsNull(Act RFU) and IsNull(Updated RFU) < Today ()[/COLOR]
IsNull returns True or False (is the value Null or not?), so I am not sure why you are trying to compare True/False values to Today().

Can you explain exactly what it is you are trying to do here?
 
Upvote 0
What your expression actually states is the following:

If BOTH:
- [Act RFU] is blank
AND
- [Comp RFU] is less than today
THEN return 1,
OTHERWISE return 0.

So it is NOT checking to see if [Act RFU] is less than today, nor is it checking to see if [Comp RFU] is blank.

Is that exactly what you want it to do?
 
Upvote 0
Sorry, Your explanation is more clear than mine. I had to re-read my statement when I read yours and your logic is clear and correct. My apologies as I am currently multitasking. What you stated below is correct. Because the actual RFU is blank the majority of the time and the Comp RFU is always a value.

If BOTH:
- [Act RFU] is blank
AND
- [Comp RFU] is less than today
THEN return 1,
OTHERWISE return 0.

I need to convert this logic to access. If possible. Thanks for the clarity.



What your expression actually states is the following:

If BOTH:
- [Act RFU] is blank
AND
- [Comp RFU] is less than today
THEN return 1,
OTHERWISE return 0.

So it is NOT checking to see if [Act RFU] is less than today, nor is it checking to see if [Comp RFU] is blank.

Is that exactly what you want it to do?
 
Upvote 0

Forum statistics

Threads
1,221,877
Messages
6,162,583
Members
451,776
Latest member
bosvinn

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top