If you take a look at the man page you see that:
* `-S` is for installing packages.
* `-F` is for querying the files database.
* `-y` refreshes the package database, and it's valid with both `-S` and `-F`.
The two major options (`-S` and `-F`) do very different things, but in both cases `-y` means "update the package database before you do anything else".