Usage of exists in oracle
1. exists is followed by a subquery
2. The following two tables are used as examples to demonstrate that the id in table a is associated with the aid in table b
Recommended learning: SQL tutorial
3. The function of exists is to check whether the result of the subquery is true. If the subquery is true, the outer SQL statement is executed. exists does not return data and only returns true or false
##4. If it returns false, the external SQL statement will not be executed as shown below 5. Its usage is somewhat similar to in, but sometimes the efficiency is different when the amount of data is relatively large, but the efficiency is the same when the amount of data is relatively small. For more oracle related tutorials, please pay attention toPHP Chinese website!
The above is the detailed content of How to use exists in oracle. For more information, please follow other related articles on the PHP Chinese website!