Specifying file or folder paths
Last updated
Last updated
The Google Drive connector provides flexibility in specifying access to files or folders. This flexibility attempts to cater to secure users' access to files or folders under various scenarios.
Users can access files/folders on the Google Drive of the Google signed-in account or shared folders shared with the Google signed-in account. The access can be through links or folder/file paths.
When using folder/file path notation and if the path starts with 'My Drive' or 'Shared with me' then it is explicit. On the other hand, if the path does not start with 'My Drive' or 'Shared with me' then it will be assumed that the path is in the Google drive of the signed-in account.
Also, in the case the folder/file path notation is used, the "Shared with me/" should be placed before the actual path of the file. Like in the following example, to access the file CustomersDataonGDrive.csv in a shared folder using folder path:
In the field "File path or File URL or Folder path or Folder URL", the file path is added with "Shared with me/" placed before it.
The field "File name" is left empty.
Files and folders can be accessed through links.
Direct file link: There is a direct link to the file to be accessed.
Folder link and File name: There is a direct link to the folder and the file name would be provided.
In the case of specifying folder or file path in the Google Drive connector Stream settings:
If the path ends with a slash '/', it means that the last item in the path is a folder. Since there is no file name in the path:
In the case of Writer, a tempuploadfile is created inside the last folder.
In the case of Reader, a file name will be provided in the "File name" field.
If the path ends without a slash '/', then the last item in the path is a file where the data will be read from or written to.
For example:
In the path /aaa/bbb/ccc/
, "aaa", "bbb", and "ccc" are all folders. In this case, a tempfile is created inside the last folder "ccc".
In the path /aaa/bbb/ccc
, "aaa" and "bbb" are the folders, while "ccc" is a file. So it will either read or write to the ccc file.
Paths can start with or without a slash. For instance, these paths will point to the same file:
/folder1/file1
folder1/file1
/my drive/folder1/file1
my drive/folder1/file1
The path to a file can be provided as follows:
Folder path including file name
Folder path excluding file name
Path to shared file
Folder path and file name