Use -q to query:
rpm -qi package_name # display info about the specified package
rpm -ql package_name # list all the files in the specified package
rpm -qa # list all installed packages
Add -p if you're querying an RPM file, omit it if you're querying an installed package.