Counting value with Date saved as Text

mart_mrexcel

Active Member
Joined
Aug 23, 2008
Messages
296
Office Version
  1. 365
Platform
  1. Windows
I have a data table with date (from SAP) and status to count the number of “inactive” in a given date. Im using the countifs formula. Problem is, Im always getting zero because the date column is extracted from SAP where it is a text format as (eg) 2022.03.01. Query, what formula I can use directly in the criteria range to directly read the SAP date as true date.

ABCDEF
1DateStatus
22022.03.01InactiveEnter Date2022-03-01
32002.06.16ActiveInactive Count=COUNTIFS($B$2:$B$6,"Inactive",$A$2:$A$6,E2)
42022.01.01
Active
52012.08.17
Active
62022.03.31Inactive
 

Excel Facts

Copy PDF to Excel
Select data in PDF. Paste to Microsoft Word. Copy from Word and paste to Excel.
Try the following
Book1
ABCDE
1DateStaus
22022.03.01Inactiveenter date2022-03-01
32002.06.16ActiveInactive Count1
42022.01.01Active
52012.08.17Active
62022.03.31Inactive
Sheet1
Cell Formulas
RangeFormula
E3E3=COUNTIFS($A$2:$A$6,TEXT($E$2,"yyyy.mm.dd"),$B$2:$B$6,"Inactive")
 
Upvote 0
Solution
Try the following
Book1
ABCDE
1DateStaus
22022.03.01Inactiveenter date2022-03-01
32002.06.16ActiveInactive Count1
42022.01.01Active
52012.08.17Active
62022.03.31Inactive
Sheet1
Cell Formulas
RangeFormula
E3E3=COUNTIFS($A$2:$A$6,TEXT($E$2,"yyyy.mm.dd"),$B$2:$B$6,"Inactive")
Thanks Kevin, that works perfect.
 
Upvote 0

Forum statistics

Threads
1,215,465
Messages
6,124,980
Members
449,201
Latest member
Lunzwe73

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