Every derived table must have its own alias (sql & php) : <pre><code>SELECT COUNT(*) AS Total FROM (
        SELECT *
        FROM `list_lazada` WHERE product_name LIKE '%$search%' 
        UNION All
        SELECT *
        FROM `list_simulation` WHERE product_name LIKE '%$search%' 
    )
</code></pre>

<p>running sql 
"Every derived table must have its own alias"</p>

<p>please help?</p>
