CSV importing computer name issues
Hey, I'm trying to import some devices from AzureAD into PDQ Inventory via CSV and it's not working as expected.
For reference, an Android AzureAD device name looks like this:
"37f9a058497bge65_AndroidEnterprise_11/3/2021_7:19 PM"
When importing, however, anything after the first space gets cut off and not imported into the "computer name" field. But if I manually import the device by name one at a time it accepts the space just fine, just not when imported via CSV.
I've tried this both with and without quotes around the device names in the imported CSV, and the same issue occurs. Is there some other character besides quotes that should be used during the import or anything else to get this to work?
Thanks.
Comments
Space characters are not valid in Windows hostnames, so the importer was likely designed with that in mind.
https://docs.microsoft.com/en-us/troubleshoot/windows-server/identity/naming-conventions-for-computer-domain-site-ou#computer-names
However, the CLI seems to accept all of those special characters:
Thanks! Didn't even think about importing via CLI. Got it working with the following
Is there any way to import data into fields other than just Custom Fields, say something like Serial or OS Name? I see it can be done one device at a time once scanning is disallowed, but that's a whole lot of manual entry.
Also, I'm seeing that Custom Fields added to the collection window don't populate their values on unscanned devices. Is that a bug maybe?
No, not without interacting with the database directly. If you want to give that a try, I have a PowerShell module named PdqStuff that makes it easier to work with the database. Just be careful, and make sure to back up your database!
I'm not sure what you're talking about. Can you share a screenshot of the issue, please?
That sounds good, I'd like to check that out.
Well it's not doing it now, but what it was doing was after adding values to a Custom Field (whether manual entry or importing) the displayed Custom Field column in the main collection window would still be empty. For example, I have a Custom Field called "Notes" which is visible in the main collection window and I was putting notes about retired computers/printers/etc. in there. The devices that had been scanned previously (older Windows devices) would populate immediately, whereas devices that had never been scanned (printers, linux servers, VMware hosts) would not populate at all. Though after the PDQ server rebooted that night all fields were populated the next day. Also, I was connecting from a PDQ console on my workstation to a PDQ central server if that's any help.