Hi!
I am new to RStudio, and have been searching across the internet for an answer for this question for days. Now I turn to the RStudio Community for help. Apologies if my question is ill-formed, as I am new to programming like this.
I am using SQL in RStudio with File -> New File -> SQL Script. What I want to know is, how can I create a local table not within a database I have established a connection with.
For instance, if I write:
create table testTable as
SELECT *
FROM obj_table
;
then the table will be created in the database I have a connection with. However, I merely want to create it as a temporary table for using in the code that would follow.
In WPS, for instance, I could write it as "create table work.testTable" specifying that it would be a temporary table, and later I could refer to it withing SQL the same way. Is something similar possible within RStudio?
Otherwise by using SQL in RStudio, how could I first load a table from a local drive, and then join it with a table from the database I have a connection with?
Thanks,
Ray