How to filter Multiple Columns in mysql , correctly
<p><a href="https://i.stack.imgur.com/SI8p0.jpg" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/SI8p0.jpg" alt="enter image description here"></a></p>

<p>This is the table ^^</p>

<p>I can filter data by entering all values in all search boxes.</p>

<p>The Query I am using is : </p>

<pre><code>SELECT * FROM `student` WHERE `cpi` &gt;= '$valueToSearch' AND `sem` = '$valueToSearch2' AND `choice` = '$valueToSearch3';
</code></pre>

<p>But when I dont enter values in all search boxes, (search with single filter) table returns nothing.</p>

<p>I used the OR keyword but its also not helping: </p>

<pre><code>SELECT * FROM `student` WHERE `cpi` &gt;= '$valueToSearch' OR `sem` = '$valueToSearch2' OR `choice` = '$valueToSearch3';
</code></pre>