ChewCheeLim

Copy AttributeCategories to a new DB

Discussion created by ChewCheeLim on Jul 6, 2012
Latest reply on Jul 9, 2012 by ChewCheeLim

Hi there, I am using ExportXML & ImportXML method to copy AttributeCategories. For some reason, the same code I am using. I can copy ElementCategories object perfectly fine. But I am not able to copy AttributeCategories.

 

Here is the xml exported from the server that I would like to copy..

 

Anything seems to be wrong ??

 

"<AF xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\" xsi:noNamespaceSchemaLocation=\"OSIsoft.AF.xsd\" SchemaVersion=\"2.0\" SoftwareVersion=\"2.4.0.4431\" ExportMode=\"NoUniqueID, Security\" PISystem=\"ENERGYMETRICSLL\" Database=\"DCMS\" Description=\"\" Created=\"2012-07-06T19:34:20.5607772Z\" id=\"8cae13cd-8cfe-43c7-a8fa-52d62c67356c\" ParentKey=\"c2986177-8024-426e-9856-9a8d583f6a0d\" ExportedObject=\"KPI\" ExportedType=\"AFCategory\" Identity=\"CategoryAttribute\" PIPersist=\"189 {9895150E-085D-4fcb-A16D-5EF5D2527196} 2\\{c8d996da-b0d7-4ad4-ba5d-502977ae2679}\\CategoriesAttribute[{8cae13cd-8cfe-43c7-a8fa-52d62c67356c}]*ENERGYMETRICSLL\\DCMS\\CategoriesAttribute[KPI]\">\r\n  <AFAttributeCategory>\r\n    <Name>KPI</Name>\r\n    <SecurityAccessControl>BUILTIN\\Administrators:A(r,w,rd,wd,d,x,a,s,so)|Everyone:A(r,rd)</SecurityAccessControl>\r\n  </AFAttributeCategory>\r\n</AF>"

 

 

 

Many thanks!

Outcomes