gam show ownership <DriveFileID>|(drivefilename <DriveFileName>) [formatjson]
gam print ownership <DriveFileID>|(drivefilename <DriveFileName>) [todrive [<ToDriveAttributes>]] [formatjson] [quotechar <Character>]
gam report drive filter="doc_id==Put File ID here" > id.csv
Open id.csv in a spreadsheet program
Look in the columns parameters.N.name for a row with the value owner; the adjacent column parameters.N.value will have the owner email address.
This only works if the file has been accessed in the last 180 days.
Ross
If I have a Drive file ID, is there any way to use that to find the owner of the file? It seems like all of the commands require the user to be one of the inputs, but is it possible without knowing who the user is?
--
You received this message because you are subscribed to the Google Groups "GAM for G Suite" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-apps-man...@googlegroups.com.
To post to this group, send email to google-ap...@googlegroups.com.
Visit this group at https://groups.google.com/group/google-apps-manager.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-apps-manager/f11da43e-771f-4097-a914-bfcdc2140449%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
And now I of course have a file not accessed within those 180 days. :-/Google is reporting failing app-script on a file, but I don't seem to have access to the file.
--
You received this message because you are subscribed to the Google Groups "GAM for G Suite" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-apps-man...@googlegroups.com.
To post to this group, send email to google-ap...@googlegroups.com.
Visit this group at https://groups.google.com/group/google-apps-manager.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-apps-manager/6fc0f537-0da8-4b92-a882-8230076489ce%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
You received this message because you are subscribed to a topic in the Google Groups "GAM for G Suite" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/google-apps-manager/FybCLt3In4c/unsubscribe.
To unsubscribe from this group and all its topics, send an email to google-apps-man...@googlegroups.com.
To post to this group, send email to google-ap...@googlegroups.com.
Visit this group at https://groups.google.com/group/google-apps-manager.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-apps-manager/CAE32uS5Kjqt-LzPw3z5RigFJ_1DQdFAOKWD3oWqZL2a8ayJceA%40mail.gmail.com.
gam user <user email> add drivefileacl <file id> user <user email>
To view this discussion on the web visit https://groups.google.com/d/msgid/google-apps-manager/CAGPzzFsUz9hb_5QxbqBn84Zok1T60A79rQv_m7g9K8pT%3DZ_sqw%40mail.gmail.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-apps-manager/CAC6ikXHcu6OmhJiLUVtzo4aY0XDicL_jO9dyFsmuhUmY%2BJ%2BWQA%40mail.gmail.com.
Rob,I added a command to do this to my Advanced GAM (https://github.com/taers232c/GAMADV-XTD)gam show ownership <DriveFileID>|(drivefilename <DriveFileName>) [formatjson]
gam print ownership <DriveFileID>|(drivefilename <DriveFileName>) [todrive [<ToDriveAttributes>]] [formatjson] [quotechar <Character>]
It is a cleaned up version of the following:gam report drive filter="doc_id==Put File ID here" > id.csv
Open id.csv in a spreadsheet program
Look in the columns parameters.N.name for a row with the value owner; the adjacent column parameters.N.value will have the owner email address.
This only works if the file has been accessed in the last 180 days.
Ross
Rob,I added a command to do this to my Advanced GAM (https://github.com/taers232c/GAMADV-XTD)gam show ownership <DriveFileID>|(drivefilename <DriveFileName>) [formatjson]
gam print ownership <DriveFileID>|(drivefilename <DriveFileName>) [todrive [<ToDriveAttributes>]] [formatjson] [quotechar <Character>]
It is a cleaned up version of the following:gam report drive filter="doc_id==Put File ID here" > id.csv
Open id.csv in a spreadsheet program
Look in the columns parameters.N.name for a row with the value owner; the adjacent column parameters.N.value will have the owner email address.
This only works if the file has been accessed in the last 180 days.
Ross
On Fri, Aug 3, 2018 at 1:55 PM Rob Barnes <robby...@springmobile.com> wrote:
If I have a Drive file ID, is there any way to use that to find the owner of the file? It seems like all of the commands require the user to be one of the inputs, but is it possible without knowing who the user is?--
You received this message because you are subscribed to the Google Groups "GAM for G Suite" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-apps-manager+unsub...@googlegroups.com.
To post to this group, send email to google-ap...@googlegroups.com.
Visit this group at https://groups.google.com/group/google-apps-manager.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-apps-manager/f11da43e-771f-4097-a914-bfcdc2140449%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
--Ross Scroggs
gam config auto_batch_min 1 redirect csv ./FileOwners.csv multiprocess redirect stderr ./FileCheck.err multiprocess all users print filelist select ids 1234,5678 fields id,name,owners.emailaddress norecursion
Hello Ross,this is fantastic! 3 questions:
- What would I need to change to search for multiple ids at once?
- if I don't get any results it means I should loop though each and every account to find the owner? which would be the most API efficient call to achieve this? I am thinking about something like this:
gam all users show fileinfo 1xeutuazvOx...wz9xVpiW21XuRSdSk
a quick test is showing me it does indeed loop though the users and I can see the info as soon as it hits an editor (or viewer?) I wonder if this is the most efficient way though ...- would it be possible to make the find owner command try to do what I suggested in Question 2 ? 😀 e.g. it could ask "Owner not found, because file was not accessed in the last 180 days. Do you want to run an extensive search? It may take some time on a large G Suite Account..."
Cheers, Markus
Am Freitag, 3. August 2018 23:49:19 UTC+2 schrieb Ross Scroggs:
Rob,I added a command to do this to my Advanced GAM (https://github.com/taers232c/GAMADV-XTD)gam show ownership <DriveFileID>|(drivefilename <DriveFileName>) [formatjson]
gam print ownership <DriveFileID>|(drivefilename <DriveFileName>) [todrive [<ToDriveAttributes>]] [formatjson] [quotechar <Character>]
It is a cleaned up version of the following:gam report drive filter="doc_id==Put File ID here" > id.csv
Open id.csv in a spreadsheet program
Look in the columns parameters.N.name for a row with the value owner; the adjacent column parameters.N.value will have the owner email address.
This only works if the file has been accessed in the last 180 days.
Ross
On Fri, Aug 3, 2018 at 1:55 PM Rob Barnes <robby...@springmobile.com> wrote:
If I have a Drive file ID, is there any way to use that to find the owner of the file? It seems like all of the commands require the user to be one of the inputs, but is it possible without knowing who the user is?--
You received this message because you are subscribed to the Google Groups "GAM for G Suite" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-apps-man...@googlegroups.com.
To post to this group, send email to google-ap...@googlegroups.com.
Visit this group at https://groups.google.com/group/google-apps-manager.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-apps-manager/f11da43e-771f-4097-a914-bfcdc2140449%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
----Ross Scroggs
You received this message because you are subscribed to the Google Groups "GAM for G Suite" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-apps-man...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-apps-manager/2389cc96-742d-44d4-b34b-3644eb49b648%40googlegroups.com.
To unsubscribe from this group and stop receiving emails from it, send an email to google-apps-manager+unsub...@googlegroups.com.
To post to this group, send email to google-ap...@googlegroups.com.
Visit this group at https://groups.google.com/group/google-apps-manager.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-apps-manager/f11da43e-771f-4097-a914-bfcdc2140449%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
--Ross Scroggs
--
You received this message because you are subscribed to the Google Groups "GAM for G Suite" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-apps-manager+unsub...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-apps-manager/2389cc96-742d-44d4-b34b-3644eb49b648%40googlegroups.com.
--Ross Scroggs
To unsubscribe from this group and stop receiving emails from it, send an email to google-apps-man...@googlegroups.com.
To post to this group, send email to google-ap...@googlegroups.com.
Visit this group at https://groups.google.com/group/google-apps-manager.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-apps-manager/f11da43e-771f-4097-a914-bfcdc2140449%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
--Ross Scroggs
--
You received this message because you are subscribed to the Google Groups "GAM for G Suite" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-apps-man...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-apps-manager/2389cc96-742d-44d4-b34b-3644eb49b648%40googlegroups.com.
----Ross Scroggs
You received this message because you are subscribed to the Google Groups "GAM for G Suite" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-apps-man...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-apps-manager/879314f8-2650-4643-b27a-d2ebf46ab727%40googlegroups.com.
To unsubscribe from this group and stop receiving emails from it, send an email to google-apps-manager+unsub...@googlegroups.com.
To post to this group, send email to google-ap...@googlegroups.com.
Visit this group at https://groups.google.com/group/google-apps-manager.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-apps-manager/f11da43e-771f-4097-a914-bfcdc2140449%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
--Ross Scroggs
--
You received this message because you are subscribed to the Google Groups "GAM for G Suite" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-apps-manager+unsub...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-apps-manager/2389cc96-742d-44d4-b34b-3644eb49b648%40googlegroups.com.
--Ross Scroggs
--
You received this message because you are subscribed to the Google Groups "GAM for G Suite" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-apps-manager+unsub...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-apps-manager/879314f8-2650-4643-b27a-d2ebf46ab727%40googlegroups.com.
To unsubscribe from this group and stop receiving emails from it, send an email to google-apps-man...@googlegroups.com.
To post to this group, send email to google-ap...@googlegroups.com.
Visit this group at https://groups.google.com/group/google-apps-manager.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-apps-manager/f11da43e-771f-4097-a914-bfcdc2140449%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
--Ross Scroggs
--
You received this message because you are subscribed to the Google Groups "GAM for G Suite" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-apps-man...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-apps-manager/2389cc96-742d-44d4-b34b-3644eb49b648%40googlegroups.com.
--Ross Scroggs
--
You received this message because you are subscribed to the Google Groups "GAM for G Suite" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-apps-man...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-apps-manager/879314f8-2650-4643-b27a-d2ebf46ab727%40googlegroups.com.
--
You received this message because you are subscribed to the Google Groups "GAM for G Suite" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-apps-man...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-apps-manager/9d8a116c-fbf8-40b5-953e-6182718670c3%40googlegroups.com.
Markus,
With print you redirect csv, not stdoutgam redirect csv ./FileOwners.csv multiprocess redirect stderr ./FileOwners.err multiprocess csv fileids.csv gam print ownership ~fileidRoss
To unsubscribe from this group and stop receiving emails from it, send an email to google-apps-manager+unsub...@googlegroups.com.
To post to this group, send email to google-ap...@googlegroups.com.
Visit this group at https://groups.google.com/group/google-apps-manager.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-apps-manager/f11da43e-771f-4097-a914-bfcdc2140449%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
--Ross Scroggs
--
You received this message because you are subscribed to the Google Groups "GAM for G Suite" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-apps-manager+unsub...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-apps-manager/2389cc96-742d-44d4-b34b-3644eb49b648%40googlegroups.com.
--Ross Scroggs
--
You received this message because you are subscribed to the Google Groups "GAM for G Suite" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-apps-manager+unsub...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-apps-manager/879314f8-2650-4643-b27a-d2ebf46ab727%40googlegroups.com.
--
You received this message because you are subscribed to the Google Groups "GAM for G Suite" group.
To unsubscribe from this group and stop receiving emails from it, send an email to google-apps-manager+unsub...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-apps-manager/9d8a116c-fbf8-40b5-953e-6182718670c3%40googlegroups.com.
--Ross Scroggs--Ross Scroggs
To unsubscribe from this group and stop receiving emails from it, send an email to google-apps-man...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/google-apps-manager/b28f84e3-8d19-4a47-a6cb-e6c513cef90b%40googlegroups.com.
Did this command give you the results you want?
gam redirect csv ./FileOwners.csv multiprocess redirect stderr ./FileOwners.err multiprocess csv fileids.csv gam print ownership ~fileid
To view this discussion on the web visit https://groups.google.com/d/msgid/google-apps-manager/b28f84e3-8d19-4a47-a6cb-e6c513cef90b%40googlegroups.com.