sqldf() from the package sqldf allows the use of SQLite queries to select and manipulate data in R. SQL queries are entered as character strings.
To select the first 10 rows of the "diamonds" dataset from the package ggplot2, for example:
data("diamonds")
head(diamonds)
#...