Is there any way to indicate a wildcard when printing users?

866 views
Skip to first unread message

Poseyjmac

unread,
Jul 28, 2017, 7:56:06 AM7/28/17
to GAM for G Suite
From a command prompt I'd like to be able to do quick wildcard searches of email addresses like this: 

gam print users primaryEmail *bob*

Is there any way to do that?

Dianne Dunlap

unread,
Jul 28, 2017, 9:58:05 PM7/28/17
to GAM for G Suite
Perhaps:
gam print users allfields | findstr bob
You can also use more sophisticated regular expressions with findstr to pick up more specific strings...

Ross Scroggs

unread,
Jul 28, 2017, 11:06:56 PM7/28/17
to google-ap...@googlegroups.com
Jonathan,

In the folder where your Gam executable resides is a file named GamCommands.txt; here are some excerpts:


gam print users [todrive] ([domain <DomainName>] [query <QueryUser>] [deleted_only|only_deleted])
        [groups] [license|licenses|licence|licences] [emailpart|emailparts|username]
[orderby <UserOrderByFieldName> [ascending|descending]] [userview]
        [allfields|basic|full | ((<UserFieldName>* | fields <UserFieldNameList>) [schemas|custom all|<SchemaNameList>])]

gam print users query "email:bob*"

--
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/16447347-84a0-4454-abd7-9ff34a70feba%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply all
Reply to author
Forward
0 new messages