## Not run:
#
#
# ## 1 Basic queries
#
# # Pass query as a simple string
# sql("SELECT username,created FROM all_users WHERE rownum<=10")
#
# # Pass query as a multiline string
# sql("SELECT extract(year from created) AS year,
# count(username) AS users
# FROM all_users
# GROUP BY extract(year from created)")
#
# # Pass query as a file
# write(c("SELECT username, created",
# "FROM all_users",
# "WHERE rownum <= 10;"), "query.sql")
# sql("query.sql")
#
#
# ## 2 Review query string, before sending it to Oracle
#
# sql(paste0("SELECT username,created FROM all_users WHERE rownum<=",5+5),
# debug=TRUE)
#
# ## End(Not run)
Run the code above in your browser using DataLab