More complicated searches can be created by comparing two values in a field.
This database contains information about different dinosaurs:
| |
| OR Searches |
An OR search finds records that match either or both of the conditions.
| Find all the dinosaurs with a length of 3 or 12 meters. |
 |
| This will find the dinosaurs: Allosaurus, Deinonychus, Coelophysis and Tyrannosaurus. |
| |
| AND Searches |
An AND search finds records that match both of the conditions.
| Find all the dinosaurs with a mass greater than 100Kg and less than 5000Kg. |
 |
| This will find the dinosaurs Allosaurus and Tenontosaurus. |
| |
| Searching in Two Different Fields |
You can put your search conditions into two different fields, but you need to take care when deciding how to combine them:
| How many dinosaurs have a length less than or equal to 10 meters AND only have 2 legs? |
 |
| This will find the dinosaurs Deinonychus and Coelophysis, so the answer is “two”. |
| How many dinosaurs have a length less than or equal to 10 meters OR only have two legs? |
 |
| This will now find seven dinosaurs – all those who have a length <=10m as well as those who have two legs. |
| |