Not returning all devices / reports
g-pearl opened this issue · 8 comments
I am working with the powershell scripts and it appears that I am not getting all the devices when I run the script it only shows 50 devices but I have 94. Is this a settings that I need to change in the script or appliance. I also see this on the reports there are 22 builtin report but when I get the list of reports it only shows 20.
The default return data is limited to 50 for devices and 20 for reports. I have made modifications in the scripts to handle this - Please pull the latest commits and see if it fixes the issue
This is working on the devices and reports but when use the invoke-reportexecution command it only return 100 items. Does a similar setting for the report output exist. Sorry to hit you with the onesie-twosie questions it is just that the warranty report is the report that I want to run and I did not know the ID until the previous update.
Thanks
The default page sizes are different across different endpoints - the scripts seem to be missing handling this in a consistent manner. I'll close out this current issue and track the changes against an umbrella issue. For now would fixing the Invoke-ReportExecution get you unblocked?
Yes that would unblock me.
I have made some changes to the Report listing and execution scripts that should work consistently for the default page sizes returned in the internal APIs. Please try them out and let me know if that works for you
When I tried to run .\Invoke-ReportExecution.ps1 -IpAddress -Credentials $cred -ReportId 94632
I get
Polling report status ...
D:\Data\Desktop\Dell OMEnt\Invoke-ReportExecution.ps1 : Exception occured - Cannot convert value "?$skip=100&$top=147"
to type "System.Int32". Error: "Input string was not in a correct format."
At line:1 char:1
Thanks I will look at the other commands as well.
When I tried to run .\Invoke-ReportExecution.ps1 -IpAddress -Credentials $cred -ReportId 94632
I get
Polling report status ...
D:\Data\Desktop\Dell OMEnt\Invoke-ReportExecution.ps1 : Exception occured - Cannot convert value "?$skip=100&$top=147"
to type "System.Int32". Error: "Input string was not in a correct format."
At line:1 char:1Thanks I will look at the other commands as well.
I've fixed and tested the fix out now on a report spanning way more than 100 returned rows in the result. Please let me know if this works for you now
Thanks - The invoke-reportexecution.ps1 works for the warranty. I will work on review the other files as well. I will close the the case at this point.