Google Drive API - Creates duplicate folders

◇◆丶佛笑我妖孽 提交于 2019-12-13 07:36:55

问题


I am developing a Java program that will upload documents to Google Drive. I found that if I try to upload to an existing folder, that I have to make sure that it is case sensitive to the existing folder. If my existing folder is on the Root labelled HDDocs, then I must input the path as "/HDDocs/10/05/01". Doing this works fine and the files are uploaded to the correct path on Google Drive - as long as I use mu personal gmail account. As soon as I try to do this on my Google Apps account, a brand new folder is created, also called HDDOcs and the files are loaded into this folder, and not the original.

So on my Google App Drive, I have two root folders labeled HDDocs.

Any feedback would be great.


回答1:


File and folder names in Google Drive are not unique, so you should't rely on that to identify your targets. Instead, you should always use the unique id.



来源:https://stackoverflow.com/questions/12185433/google-drive-api-creates-duplicate-folders

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!