Forum Discussion

Dollypee's avatar
Dollypee
Moderator
10 years ago

Opscenter analytic to generate all client report

Opscenter version : 7.6.0.4

Team,

I would like to generate following report from my opscenter analytic using sql query. Please help.

 

- Master server

- Host (client name)

- Operating system

- OS type

- Host type

- Version

- Status

 

 

Thank you

 

  • Hi Dolly,

    In this case custom report should work just fine.

    Execute code below once, don't save it as a report. Perhaps, I'm reinventing a wheel, but I couldn't find such procedure in base package.

    CREATE FUNCTION SecToTime(seconds INT)
    RETURNS CHAR(20)
    AS
    BEGIN
    RETURN (
    	(SELECT RIGHT('00' + CAST(CAST(floor(seconds/3600) as NUMERIC(3)) as CHAR(3)), 2)) + ':' + 
    	(SELECT RIGHT('00' + CAST(CAST(floor(seconds/60) % 60 as NUMERIC(2)) as CHAR(2)), 2)) +':' + 
    	(SELECT RIGHT('00' + CAST(CAST(seconds % 60 as NUMERIC(2)) as CHAR(2)), 2))
    )
    END

    Your report is in attachment, remove extra columns if you don't need them.

4 Replies

  • Hi Dolly,

    In this case custom report should work just fine.

    Execute code below once, don't save it as a report. Perhaps, I'm reinventing a wheel, but I couldn't find such procedure in base package.

    CREATE FUNCTION SecToTime(seconds INT)
    RETURNS CHAR(20)
    AS
    BEGIN
    RETURN (
    	(SELECT RIGHT('00' + CAST(CAST(floor(seconds/3600) as NUMERIC(3)) as CHAR(3)), 2)) + ':' + 
    	(SELECT RIGHT('00' + CAST(CAST(floor(seconds/60) % 60 as NUMERIC(2)) as CHAR(2)), 2)) +':' + 
    	(SELECT RIGHT('00' + CAST(CAST(seconds % 60 as NUMERIC(2)) as CHAR(2)), 2))
    )
    END

    Your report is in attachment, remove extra columns if you don't need them.

  • Hi V, I need to mark you post as solution but for some reason can't find the option. Forum admin please assit. Thank you