if (FALSE) { # identical(Sys.getenv("IN_PKGDOWN"), "TRUE")
# Create and read a simple JSON file
path <- tempfile("duckplyr_test_", fileext = ".json")
writeLines('[{"a": 1, "b": "x"}, {"a": 2, "b": "y"}]', path)
# Reading needs the json extension
db_exec("INSTALL json")
db_exec("LOAD json")
read_json_duckdb(path)
}
Run the code above in your browser using DataLab