id,node_id,number,title,user,state,locked,assignee,milestone,comments,created_at,updated_at,closed_at,author_association,active_lock_reason,draft,pull_request,body,reactions,performed_via_github_app,state_reason,repo,type
329066551,MDU6SXNzdWUzMjkwNjY1NTE=,2213,xarray.Dataset.sel(time='2007-04-12') returns unexpected time dimension,7643370,closed,0,,,7,2018-06-04T13:56:05Z,2023-12-02T02:54:11Z,2023-12-02T02:54:11Z,NONE,,,,"#### Code Sample
![image](https://user-images.githubusercontent.com/7643370/40920453-e4952098-680c-11e8-8f9c-148b39a8f591.png)
![image](https://user-images.githubusercontent.com/7643370/40920483-ff212e7a-680c-11e8-9d30-c581ac1a38ae.png)
![image](https://user-images.githubusercontent.com/7643370/40920502-0a197ab2-680d-11e8-855c-73524e996d75.png)


#### Problem description

The current behaviour of xarray.Dataset.sel when selecting time is that it returns a 3D array with the time dimension has a length of 0. 

#### Expected Output

I expect that no time dimension is returned. This behaviour is as expected in xarray.Dataset.isel (look at the Jupyter Notebook screenshot above). 

#### Output of ``xr.show_versions()``

<details>
INSTALLED VERSIONS
------------------
commit: None
python: 3.5.2.final.0
python-bits: 64
OS: Windows
OS-release: 10
machine: AMD64
processor: Intel64 Family 6 Model 63 Stepping 2, GenuineIntel
byteorder: little
LC_ALL: None
LANG: None
LOCALE: None.None

xarray: 0.10.3
pandas: 0.19.0
numpy: 1.11.3
scipy: 1.1.0
netCDF4: 1.2.2
h5netcdf: 0.2.2
h5py: 2.6.0
Nio: None
zarr: None
bottleneck: 1.2.1
cyordereddict: 1.0.0
dask: 0.14.1
distributed: 1.21.8
matplotlib: 2.2.2
cartopy: None
seaborn: 0.8.1
setuptools: 27.2.0.post20161106
pip: 9.0.1
conda: None
pytest: 3.6.0
IPython: 6.4.0
sphinx: None

</details>
","{""url"": ""https://api.github.com/repos/pydata/xarray/issues/2213/reactions"", ""total_count"": 0, ""+1"": 0, ""-1"": 0, ""laugh"": 0, ""hooray"": 0, ""confused"": 0, ""heart"": 0, ""rocket"": 0, ""eyes"": 0}",,not_planned,13221727,issue