Get Rows based on distinct values from Column 2 : <p>I am a newbie to pandas, tried searching this on google but still no luck. How can I get the rows by distinct values in column2?</p>

<p>For example, I have the dataframe bellow:</p>

<pre><code>&gt;&gt;&gt; df
COL1   COL2
a.com  22
b.com  45
c.com  34
e.com  45
f.com  56
g.com  22
h.com  45
</code></pre>

<p>I want to get the rows based on unique values in COL2</p>

<pre><code>&gt;&gt;&gt; df
COL1  COL2
a.com 22
b.com 45
c.com 34
f.com 56
</code></pre>

<p>So, how can I get that? I would appreciate it very much if anyone can provide any help.</p>
