<h4 dir="auto">Code Sample, a copy-pastable example if possible</h4>
<div class="highlight highlight-source-python notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="In [2]: df1 = pd.DataFrame([{'A': None, 'B': 1}, {'A': 2, 'B': 2}])
   ...: df2 = pd.DataFrame([{'A': 3, 'B': 3}, {'A': 4, 'B': 4}])
   ...: df = pd.concat([df1, df2], axis=1)
   ...: df.iloc[0, 0] = df.iloc[0, 2]
   ...: df
   ...: 
Out[2]: 
     A  B    A  B
0  3.0  1  3.0  3
1  2.0  2  4.0  4"><pre class="notranslate"><span class="pl-v">In</span> [<span class="pl-c1">2</span>]: <span class="pl-s1">df1</span> <span class="pl-c1">=</span> <span class="pl-s1">pd</span>.<span class="pl-v">DataFrame</span>([{<span class="pl-s">'A'</span>: <span class="pl-c1">None</span>, <span class="pl-s">'B'</span>: <span class="pl-c1">1</span>}, {<span class="pl-s">'A'</span>: <span class="pl-c1">2</span>, <span class="pl-s">'B'</span>: <span class="pl-c1">2</span>}])
   ...: <span class="pl-s1">df2</span> <span class="pl-c1">=</span> <span class="pl-s1">pd</span>.<span class="pl-v">DataFrame</span>([{<span class="pl-s">'A'</span>: <span class="pl-c1">3</span>, <span class="pl-s">'B'</span>: <span class="pl-c1">3</span>}, {<span class="pl-s">'A'</span>: <span class="pl-c1">4</span>, <span class="pl-s">'B'</span>: <span class="pl-c1">4</span>}])
   ...: <span class="pl-s1">df</span> <span class="pl-c1">=</span> <span class="pl-s1">pd</span>.<span class="pl-en">concat</span>([<span class="pl-s1">df1</span>, <span class="pl-s1">df2</span>], <span class="pl-s1">axis</span><span class="pl-c1">=</span><span class="pl-c1">1</span>)
   ...: <span class="pl-s1">df</span>.<span class="pl-s1">iloc</span>[<span class="pl-c1">0</span>, <span class="pl-c1">0</span>] <span class="pl-c1">=</span> <span class="pl-s1">df</span>.<span class="pl-s1">iloc</span>[<span class="pl-c1">0</span>, <span class="pl-c1">2</span>]
   ...: <span class="pl-s1">df</span>
   ...: 
<span class="pl-v">Out</span>[<span class="pl-c1">2</span>]: 
     <span class="pl-v">A</span>  <span class="pl-v">B</span>    <span class="pl-v">A</span>  <span class="pl-v">B</span>
<span class="pl-c1">0</span>  <span class="pl-c1">3.0</span>  <span class="pl-c1">1</span>  <span class="pl-c1">3.0</span>  <span class="pl-c1">3</span>
<span class="pl-c1">1</span>  <span class="pl-c1">2.0</span>  <span class="pl-c1">2</span>  <span class="pl-c1">4.0</span>  <span class="pl-c1">4</span></pre></div>
<h4 dir="auto">Problem description</h4>
<p dir="auto">The third column shouldn't have changed type</p>
<h4 dir="auto">Expected Output</h4>
<div class="highlight highlight-source-python notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="Out[2]: 
     A  B  A  B
0  3.0  1  3  3
1  2.0  2  4  4"><pre class="notranslate"><span class="pl-v">Out</span>[<span class="pl-c1">2</span>]: 
     <span class="pl-v">A</span>  <span class="pl-v">B</span>  <span class="pl-v">A</span>  <span class="pl-v">B</span>
<span class="pl-c1">0</span>  <span class="pl-c1">3.0</span>  <span class="pl-c1">1</span>  <span class="pl-c1">3</span>  <span class="pl-c1">3</span>
<span class="pl-c1">1</span>  <span class="pl-c1">2.0</span>  <span class="pl-c1">2</span>  <span class="pl-c1">4</span>  <span class="pl-c1">4</span></pre></div>
<h4 dir="auto">Output of <code class="notranslate">pd.show_versions()</code></h4>
<details>
<h2 dir="auto">INSTALLED VERSIONS</h2>
<p dir="auto">commit: <a class="commit-link" data-hovercard-type="commit" data-hovercard-url="https://github.com/pandas-dev/pandas/commit/32df1e6ae452f7ddd31dc41fa613992493eb51c4/hovercard" href="https://github.com/pandas-dev/pandas/commit/32df1e6ae452f7ddd31dc41fa613992493eb51c4"><tt>32df1e6</tt></a><br>
python: 3.5.3.final.0<br>
python-bits: 64<br>
OS: Linux<br>
OS-release: 4.7.0-1-amd64<br>
machine: x86_64<br>
processor:<br>
byteorder: little<br>
LC_ALL: None<br>
LANG: it_IT.utf8<br>
LOCALE: it_IT.UTF-8</p>
<p dir="auto">pandas: 0.19.0+597.g32df1e6ae<br>
pytest: 3.0.6<br>
pip: 9.0.1<br>
setuptools: 33.1.1<br>
Cython: 0.25.2<br>
numpy: 1.12.0<br>
scipy: 0.18.1<br>
xarray: None<br>
IPython: 5.1.0.dev<br>
sphinx: 1.4.9<br>
patsy: 0.3.0-dev<br>
dateutil: 2.5.3<br>
pytz: 2016.7<br>
blosc: None<br>
bottleneck: 1.2.0<br>
tables: 3.3.0<br>
numexpr: 2.6.1<br>
feather: 0.3.1<br>
matplotlib: 2.0.0<br>
openpyxl: 2.3.0<br>
xlrd: 1.0.0<br>
xlwt: 1.1.2<br>
xlsxwriter: 0.9.6<br>
lxml: 3.7.1<br>
bs4: 4.5.3<br>
html5lib: 0.999999999<br>
sqlalchemy: 1.0.15<br>
pymysql: None<br>
psycopg2: None<br>
jinja2: 2.8<br>
s3fs: None<br>
pandas_gbq: None<br>
pandas_datareader: 0.2.1</p>
</details>
<p dir="auto">This is a continuation of <a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="166162646" data-permission-text="Title is private" data-url="https://github.com/pandas-dev/pandas/issues/13695" data-hovercard-type="issue" data-hovercard-url="/pandas-dev/pandas/issues/13695/hovercard" href="https://github.com/pandas-dev/pandas/issues/13695">#13695</a>.</p>
<p dir="auto">Starting with the original DataFrames from that issue:</p>
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="df1 = pd.DataFrame({'time':pd.to_datetime(['2016-07-15 13:30:00.030']), 'username':['bob']})
df2 = pd.DataFrame({'time':pd.to_datetime(['2016-07-15 13:30:00.000', '2016-07-15 13:30:00.030']), 'version':[1, 2]})"><pre class="notranslate"><code class="notranslate">df1 = pd.DataFrame({'time':pd.to_datetime(['2016-07-15 13:30:00.030']), 'username':['bob']})
df2 = pd.DataFrame({'time':pd.to_datetime(['2016-07-15 13:30:00.000', '2016-07-15 13:30:00.030']), 'version':[1, 2]})
</code></pre></div>
<p dir="auto">I now get the null:</p>
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="In [82]: pd.merge_asof(df1, df2, on='time', allow_exact_matches=False, tolerance=pd.Timedelta('10ms'))
Out[82]:
                     time username  version
0 2016-07-15 13:30:00.030      bob      NaN"><pre class="notranslate"><code class="notranslate">In [82]: pd.merge_asof(df1, df2, on='time', allow_exact_matches=False, tolerance=pd.Timedelta('10ms'))
Out[82]:
                     time username  version
0 2016-07-15 13:30:00.030      bob      NaN
</code></pre></div>
<p dir="auto">However, if I change the first DataFrame to have duplicate timestamps:</p>
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="df1 = pd.DataFrame({'time':pd.to_datetime(['2016-07-15 13:30:00.030', '2016-07-15 13:30:00.030']), 'username':['bob', 'charlie']})"><pre class="notranslate"><code class="notranslate">df1 = pd.DataFrame({'time':pd.to_datetime(['2016-07-15 13:30:00.030', '2016-07-15 13:30:00.030']), 'username':['bob', 'charlie']})
</code></pre></div>
<p dir="auto">then the bug reappears:</p>
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="In [85]: pd.merge_asof(df1, df2, on='time', allow_exact_matches=False, tolerance=pd.Timedelta('10ms'))
Out[85]:
                     time username  version
0 2016-07-15 13:30:00.030      bob        1
1 2016-07-15 13:30:00.030  charlie        1"><pre class="notranslate"><code class="notranslate">In [85]: pd.merge_asof(df1, df2, on='time', allow_exact_matches=False, tolerance=pd.Timedelta('10ms'))
Out[85]:
                     time username  version
0 2016-07-15 13:30:00.030      bob        1
1 2016-07-15 13:30:00.030  charlie        1
</code></pre></div>
<p dir="auto">This is in pandas version 0.18.0+418.gc46dcfa.</p>