<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Retrieve users and their devices in Management</title>
    <link>https://community.cisco.com/t5/management/retrieve-users-and-their-devices/m-p/3461518#M742</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I am using AXL to retrieve the users and their devices from the call manager. I followed the following way:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;I made a SOAP call to "listUser" API.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Then for each user in the list, I made a SOAP call to "getUser" API. This API gives me the list of associated devices for each user.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;But according to some of our customers, this is not right way to get users and their devices. According to them the way is:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Make a SOAP call to "listPhone" SOAP API. The "ownerUserID" field will give the user name.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Now my question is the following?&lt;/P&gt;&lt;P&gt;What is the right way to retrieve the users and their associated devices. This is important for our customers as they have a "User" based licensing scheme.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 05 Feb 2016 14:33:07 GMT</pubDate>
    <dc:creator>Anshu.Garg1</dc:creator>
    <dc:date>2016-02-05T14:33:07Z</dc:date>
    <item>
      <title>Retrieve users and their devices</title>
      <link>https://community.cisco.com/t5/management/retrieve-users-and-their-devices/m-p/3461518#M742</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I am using AXL to retrieve the users and their devices from the call manager. I followed the following way:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;I made a SOAP call to "listUser" API.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Then for each user in the list, I made a SOAP call to "getUser" API. This API gives me the list of associated devices for each user.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;But according to some of our customers, this is not right way to get users and their devices. According to them the way is:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Make a SOAP call to "listPhone" SOAP API. The "ownerUserID" field will give the user name.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Now my question is the following?&lt;/P&gt;&lt;P&gt;What is the right way to retrieve the users and their associated devices. This is important for our customers as they have a "User" based licensing scheme.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 05 Feb 2016 14:33:07 GMT</pubDate>
      <guid>https://community.cisco.com/t5/management/retrieve-users-and-their-devices/m-p/3461518#M742</guid>
      <dc:creator>Anshu.Garg1</dc:creator>
      <dc:date>2016-02-05T14:33:07Z</dc:date>
    </item>
    <item>
      <title>Re: Retrieve users and their devices</title>
      <link>https://community.cisco.com/t5/management/retrieve-users-and-their-devices/m-p/3461519#M743</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I think the listPhone approach is good, but may only work if the administrative has configured the 'Owner User ID' field for the device in the phone's config:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG alt="Screenshot from 2016-02-05 09-41-39.png" class="image-1 jive-image" src="/legacyfs/online/fusion/92736_Screenshot from 2016-02-05 09-41-39.png" style="height: 75px; width: 620px;" /&gt;&lt;/P&gt;&lt;P&gt;Another option for bulk retrieval, if users/phones are associated but Owner User ID is not used, is a custom SQL query, via executeSqlQuery.&amp;nbsp; E.g.:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;BLOCKQUOTE&gt;&lt;TABLE border="1"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD&gt;
&lt;P&gt;&lt;SPAN&gt;&amp;lt;soapenv:Envelope xmlns:soapenv="&lt;/SPAN&gt;&lt;A class="jive-link-external-small" href="http://schemas.xmlsoap.org/soap/envelope/" rel="nofollow" target="_blank"&gt;http://schemas.xmlsoap.org/soap/envelope/&lt;/A&gt;&lt;SPAN&gt;" xmlns:ns="&lt;/SPAN&gt;&lt;A class="jive-link-external-small" href="http://www.cisco.com/AXL/API/10.5" rel="nofollow" target="_blank"&gt;http://www.cisco.com/AXL/API/10.5&lt;/A&gt;&lt;SPAN&gt;"&amp;gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp; &amp;lt;soapenv:Header/&amp;gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp; &amp;lt;soapenv:Body&amp;gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;ns:executeSQLQuery&amp;gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;sql&amp;gt;select enduser.userid, device.name from enduser,device,enduserdevicemap &lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; where enduserdevicemap.fkenduser=enduser.pkid and enduserdevicemap.fkdevice=device.pkid&amp;lt;/sql&amp;gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;lt;/ns:executeSQLQuery&amp;gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&amp;nbsp; &amp;lt;/soapenv:Body&amp;gt;&lt;/P&gt;
&lt;P&gt;&amp;lt;/soapenv:Envelope&amp;gt;&lt;/P&gt;
&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;/BLOCKQUOTE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 05 Feb 2016 15:52:18 GMT</pubDate>
      <guid>https://community.cisco.com/t5/management/retrieve-users-and-their-devices/m-p/3461519#M743</guid>
      <dc:creator>dstaudt</dc:creator>
      <dc:date>2016-02-05T15:52:18Z</dc:date>
    </item>
    <item>
      <title>Re: Retrieve users and their devices</title>
      <link>https://community.cisco.com/t5/management/retrieve-users-and-their-devices/m-p/3461520#M744</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I will re-phrase my question:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Cisco has more than 1 way to enforce licensing:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="http://www.cisco.com/c/en/us/td/docs/voice_ip_comm/cucm/admin/10_0_1/ccmfeat/CUCM_BK_F3AC1C0F_00_cucm-features-services-guide-100/CUCM_BK_F3AC1C0F_00_cucm-features-services-guide-100_chapter_0100101.html#CUCM_RF_U75FBF1E_00" title="http://www.cisco.com/c/en/us/td/docs/voice_ip_comm/cucm/admin/10_0_1/ccmfeat/CUCM_BK_F3AC1C0F_00_cucm-features-services-guide-100/CUCM_BK_F3AC1C0F_00_cucm-features-services-guide-100_chapter_0100101.html#CUCM_RF_U75FBF1E_00"&gt;http://www.cisco.com/c/en/us/td/docs/voice_ip_comm/cucm/admin/10_0_1/ccmfeat/CUCM_BK_F3AC1C0F_00_cucm-features-services-guide-100/CUCM_BK_F3AC1C0F_00_cucm-features-services-guide-100_chapter_0100101.html#CUCM_RF_U75FBF1E_00&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If the customer has "Device Only" licensing model, it is easy to count the devices using the AXL API.&lt;/P&gt;&lt;P&gt;But my question is more for those customers, who have User or User and Device type of licensing model.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In that scenario, how do we get the users and their devices?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Anshu&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 10 Feb 2016 17:03:40 GMT</pubDate>
      <guid>https://community.cisco.com/t5/management/retrieve-users-and-their-devices/m-p/3461520#M744</guid>
      <dc:creator>Anshu.Garg1</dc:creator>
      <dc:date>2016-02-10T17:03:40Z</dc:date>
    </item>
    <item>
      <title>Re: Retrieve users and their devices</title>
      <link>https://community.cisco.com/t5/management/retrieve-users-and-their-devices/m-p/3461521#M745</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;the CUCM have four ways for device association.&lt;/P&gt;&lt;P&gt;1. with extension mobility&lt;/P&gt;&lt;P&gt;2. with the owner field under the device configuration.&lt;/P&gt;&lt;P&gt;3. under the enduser during the Device associate button in Cucm admin page.&lt;/P&gt;&lt;P&gt;4. you can associate device mobility too like remote destination profile.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;so first you should to ask the right question &lt;IMG src="https://community.cisco.com/legacyfs/online/emoticons/happy.png" /&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You can try the following queries:&lt;/P&gt;&lt;P&gt;push the queries into the CLI of Publisher by SSH access, use the "run sql" command.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Devices and Device profiles (During EM) that have associate with enduser by userid filter&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;select fkdevice from enduserdevicemap where fkenduser=(select eu.pkid from enduser as eu where eu.userid like '&lt;SPAN style="font-size: 13.3333px;"&gt;&amp;lt;Insert the UserID&amp;gt;&lt;/SPAN&gt;')&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Device Mobility that have associate with enduser by userid filter&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;select pkid from device where fkenduser_mobility=(select eu.pkid from enduser as eu where eu.userid like '&lt;SPAN style="font-size: 13.3333px;"&gt;&amp;lt;Insert the UserID&amp;gt;&lt;/SPAN&gt;')&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;All Devices that configured with Owner User ID field and have associate with enduser by userid filter&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;select name from device where fkenduser=(select eu.pkid from enduser as eu where eu.userid like '&amp;lt;Insert the UserID&amp;gt;')&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;It will show you something like this:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;name&lt;/P&gt;&lt;P&gt;===============&lt;/P&gt;&lt;P&gt;SEP189C5DB68537&lt;/P&gt;&lt;P&gt;SEPC067AF582A37&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If you still want to use AXL function, use executeSQLqueryreq, see my simple program in C#&lt;/P&gt;&lt;P&gt;string sqlquery = "&amp;lt;Insert the SQL query&amp;gt;";&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ExecuteSQLQueryReq sqlqueryreq = new ExecuteSQLQueryReq();&lt;/P&gt;&lt;P&gt;sqlqueryreq.sql = sqlquery;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;ExecuteSQLQueryRes res = new ExecuteSQLQueryRes();&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;try&lt;/P&gt;&lt;P&gt;{&lt;/P&gt;&lt;P&gt;&amp;nbsp; res = &amp;lt;The_APIObject_reference&amp;gt;.executeSQLQuery(sqlqueryreq);&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; foreach (XmlNode[] node in res.@return)&lt;/P&gt;&lt;P&gt;&amp;nbsp; {&lt;/P&gt;&lt;P&gt;&amp;nbsp; do something with the res object&lt;/P&gt;&lt;P&gt;&amp;nbsp; }&lt;/P&gt;&lt;P&gt;}&lt;/P&gt;&lt;P&gt;catch (NullReferenceException) {}&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 17 Mar 2016 22:34:40 GMT</pubDate>
      <guid>https://community.cisco.com/t5/management/retrieve-users-and-their-devices/m-p/3461521#M745</guid>
      <dc:creator>lior look</dc:creator>
      <dc:date>2016-03-17T22:34:40Z</dc:date>
    </item>
  </channel>
</rss>

