Custom query with more than one field on az ad sp list

Lets say I want to list id and appId from az ad sp list, how would one do that? I get it working for only the id like this: az ad sp list –query ‘[].id’ How can I extend this to id and appId? I already tried az ad sp list –query ‘[].id,[].appId’ az ad… Read More Custom query with more than one field on az ad sp list

Return objects in list that the first name starts with a certain value (jmespath)

I am trying to filter through this list of objects and only return the objects where the firstName starts with a specific value. [ {"firstName":"Paul","lastName":"Collins"}, {"firstName":"Jerry","lastName":"Johnson"}, {"firstName":"Jody","lastName":"Johnson","occupation":"Occupado","company":"Companio"}, {"firstName":"Paul","lastName":"Johanson","occupation":"Developer","company":"Developer Co"} ] The farthest I’ve gotten is this: ([].firstName | [?starts_with(@,’J’) == `true`]) Which returns: [ "Jerry", "Jody" ] However, I want to return whole objects that… Read More Return objects in list that the first name starts with a certain value (jmespath)