What are the restrictions, in terms of a number of rows and columns, with MySQL query having no table list?


The restriction on MySQL query having a notable list is that it can return, as a result, exactly one row but that result can contain multiple columns.

Example

mysql> Select 65/NULL,65+NULL,65*NULL,65-NULL,65%NULL;
+------------+--------------+-------------+-------------+---------+
| 65/NULL    | 65+NULL      | 65*NULL     | 65-NULL     | 65%NULL |
+------------+--------------+-------------+-------------+---------+
|       NULL |         NULL |        NULL |        NULL |    NULL |
+------------+--------------+-------------+-------------+---------+
1 row in set (0.00 sec)

In the above example, we can see that MySQL returns only one row with five columns, having the result of five expressions, as a result when we do not have any table list in the statement.

Updated on: 22-Jun-2020

44 Views

Kickstart Your Career

Get certified by completing the course

Get Started
Advertisements