I am reading a xlsx-file via oledb. There are some rows where a column (containing a date-string) returns null and some rows where the column (also containing a date-string) returns the date-string. In excel the column-type is set to "date".

Here is my connection-string:

> 
> $"Provider=Microsoft.ACE.OLEDB.12.0;Data
>  Source={PATH\_TO\_FILE};Extended Properties=\"Excel 12.0
>  Xml;HDR=NO\""
> 
> 
> 

Here is the command-text to query the data:

> 
> $"SELECT \* FROM [SHEET\_NAME$A4:BC] WHERE
>  F1 IS NOT NULL"
> 
> 
> 

Here is how i read the data from the data-record:

```
var test = dataRecord.GetValue(dataRecord.GetOrdinal("F39"));

```

Her are some examples what the inspector shows me when test contains the date-string:

```
{07.01.1975 00:00:00}
{03.08.1987 00:00:00}
{03.10.1988 00:00:00}
{01.05.1969 00:00:00}
{20.12.2016 00:00:00}
{18.07.2011 00:00:00}

```

In other cases the inspector only show:

```
{}

```

Here is a screenshot from the xlsx-document where i have marked a line in red where the return-value is empty and green where the actual date-string is returned:

[![enter image description here](https://i.stack.imgur.com/Op7nQ.png)](https://i.stack.imgur.com/Op7nQ.png)

The date-strings are formatted like `dd.mm.yyyy` 

Why do these rows return an empty value instead of the date-string?

---

As suggested by AndyG i have checked if the date-string values might fail in dependece of the format ("dd.mm.yyyy" vs. "mm.dd.yyyy"). But there are cases which are invalid for "mm.dd.yyyy" that dont fail.