wmic diskdrive command invalid query

Microsoft Windows
Post Reply
SweetTasha
Posts: 10
Joined: 2021-Sep-11, 4:24 am

wmic diskdrive command invalid query

Post by SweetTasha »

wmic diskdrive getName, Manufacturer, Model, InterfaceType, MediaType, SerialNumber
I got this command from an article explaining how to get the volume serial number for my System Hard Drive. I also need to use it for other drives, such as USB flash drives.
Here's an image of the Command Prompt
command invalid query.png[/attachment]

EDIT: I notice that the image does not show that the command Prompt was running as an administrator. I haverun as an administrator and it gets the same error.
TIA for your help.
SweetTasha
Attachments
wmic command invalid query.png
wmic command invalid query.png (11.95 KiB) Viewed 2156 times
User avatar
Simon Sheppard
Posts: 190
Joined: 2021-Jul-10, 7:46 pm
Contact:

Re: wmic diskdrive command invalid query

Post by Simon Sheppard »

instead of wmic diskdrive getName ...
try wmic diskdrive get Name ...
SweetTasha
Posts: 10
Joined: 2021-Sep-11, 4:24 am

Re: wmic diskdrive command invalid query

Post by SweetTasha »

get name fixed it. thanks. SweetTasha
Post Reply