cancel
Showing results for 
Search instead for 
Did you mean: 

Monthly devices count in Afaria server

Former Member
0 Kudos

Hi there,

We are trying to automate the reports for Afaria.

Is it possible to get the device count registered in Afaria on per month basis?

Any particular API we should refer for this?!

Any suggestion would be helpful..

Regards,

Suraj

Accepted Solutions (1)

Accepted Solutions (1)

former_member207653
Active Participant
0 Kudos

Hi Suraj,

Afaria database stores all data you need.

For example, A_DEVICE table has the list of devices including their names, GUID numbers and when they connected to Afaria server the very first time. ClientCategory column is the device type (iOS, Android, Windows Phone, and so on) that you can work out referencing the content of the A_CLIENT_CATEGORY_NAME_MAP table.

There is a set of Afaria API that you could use. Search for Afaria  API Commands manual in the link below

SAP Afaria 7 SP5 On Premise – SAP Help Portal Page

and the following content for a few examples about how to use those APIs:

http://scn.sap.com/docs/DOC-54527

http://scn.sap.com/docs/DOC-58943

Thank you,

Mirco

Former Member
0 Kudos

We have a scheduled task running in SQL Server that stores the device count for each tenant every day. We then have queries to report the device count on a monthly basis

BR

Peter

Former Member
0 Kudos

Hi Mirco,

Thanks for the links

Former Member
0 Kudos

Hi Peter,

Could you specify which table you are referring to, for this?

It would be helpful!

Former Member
0 Kudos

We store the count from the A_V_ALL_Clients view like this:

    Insert Into MA_TenantClientCount

  Select GetDate() as ScanDate, A_V_ALL_CLIENTS.TenantID, COUNT(*) as Clients

  from A_V_ALL_CLIENTS INNER JOIN A_TENANT ON A_V_ALL_CLIENTS.TenantID = A_TENANT.TenantID

  Where ClientCategory <> -9 and ClientCategory <> -1 AND Approved = 1

  Group By A_V_ALL_CLIENTS.TenantID

this runs daily

Peter

former_member207653
Active Participant
0 Kudos

Not a problem.

Please, remember to mark this question as answered or any answer as useful if you think we are done.

Thank you,

Mirco

Answers (0)