I would like to use a string of character IDs in the WHERE clause of SQL query. My id object looks like this
ids
[1] "0000000000000000010000001" "0000000000000000010000002" "0000000000000000010000003"
[4] "0000000000000000010000004" "0000000000000000010000005" "0000000000000000010000006"
[7] "0000000000000000010000007" "0000000000000000010000008" "0000000000000000010000009"
[10] "0000000000000000010000010"
I would like to insert that object into this SQL query:
student <- sqlQuery(con,
"select
FSAS.a_id,
FSAS.grade,
FSAS.score,
FSAS.placement,
FSAS.start,
FSAS.completion
FROM db.Fact AS FSAS
WHERE FSAS.a_id IN ids"
)
I think the entire SQL query has to be a string but I can't figure out how to get it right.