Working with CSV, XML, and JSON rights files

Use the following information to write or correct a rights import file. Included below are sample files and a table containing the required syntax.

Note: 

You must define blank column values in your import file. Since Excel might not delimit blank field values, you may need to use a text editor to provide blank column values.

Example CSV File

A,lawson,CEO,Company Structure,Company,equal to,10,,1,1,lawson,,
A,lawson,CEO,Company Structure,ACCOUNTING UNIT,equal to,1*,,1,2,lawson,,
A,lawson,CEO,Company Structure,Company,equal to,20,,2,1,lawson,, A,lawson,CEO,Company
Structure,ACCOUNTING UNIT,equal to,1*,,2,2,lawson,, A,1104,EPM DEV
MGR,Company Structure,Company,equal to,1,,1,1,lawson,2/1/2001, A,1104,EPM
DEV MGR,Company Structure,ACCOUNTING UNIT,equal to,2885,,1,2,lawson,
2/1/2001, A,1143,EPM DEV DIRECTOR,Company Structure,Company,equal
to,1,,1,1,lawson,1/1/1991, A,1143,EPM DEV DIRECTOR,Company Structure,ACCOUNTING
UNIT,equal to,2885,,1,2,
lawson,1/1/1991, A,2885,EPM
VICE PRESIDENT,Company Structure,Company,equal to,1,,1,1,lawson,
1/1/2005, A,2885,EPM VICE PRESIDENT,Company Structure,ACCOUNTING
UNIT,equal to,2885,,1,2,
lawson,1/1/2006,7/31/07

Example XML File

<?xml version="1.0" encoding="UTF-8"?> 
 <content> 
 <row id="1"> 
 <actionmode><![CDATA[A]]></actionmode> 
 <consumerid><![CDATA[15137]]></consumerid> 
 <rulename><![CDATA[LBI-5055]]></rulename> 
 <structurename><![CDATA[CO_AU]]></structurename> 
 <elementname><![CDATA[COMPANY]]></elementname> 
 <operand><![CDATA[equal to]]></operand> 
 <elementvalue1><![CDATA[2000]]></elementvalue1> 
 <elementvalue2/> 
 <rulegrouping><![CDATA[1]]></rulegrouping> 
 <elementorder><![CDATA[1]]></elementorder> 
 <ruleowner><![CDATA[15137]]></ruleowner> 
 <startdate_date><![CDATA[2/24/2011]]></startdate_date> 
 <enddate_date><![CDATA[12/31/2099]]></enddate_date> 
 </row> 
 <row id="2"> 
 <actionmode><![CDATA[A]]></actionmode> 
 <consumerid><![CDATA[15137]]></consumerid> 
 <rulename><![CDATA[LBI-5055]]></rulename> 
 <structurename><![CDATA[CO_AU]]></structurename> 
 <elementname><![CDATA[ACCOUNTING UNIT]]></elementname> 
 <operand><![CDATA[equal to]]></operand> 
 <elementvalue1><![CDATA[901207]]></elementvalue1> 
 <elementvalue2/> 
 <rulegrouping><![CDATA[1]]></rulegrouping> 
 <elementorder><![CDATA[2]]></elementorder> 
 <ruleowner><![CDATA[15137]]></ruleowner> 
 <startdate_date><![CDATA[2/24/2011]]></startdate_date> 
 <enddate_date><![CDATA[12/31/2099]]></enddate_date> 
 </row> 
 <row id="3"> 
 <actionmode><![CDATA[A]]></actionmode> 
 <consumerid><![CDATA[15137]]></consumerid> 
 <rulename><![CDATA[companyStringString1String2String3]]></rulename> 
 <structurename><![CDATA[CompanyStringString1String2String3]]></structurename> 
 <elementname><![CDATA[string3]]></elementname> 
 <operand><![CDATA[within range of]]></operand> 
 <elementvalue1><![CDATA[060000]]></elementvalue1> 
 <elementvalue2><![CDATA[069999]]></elementvalue2> 
 <rulegrouping><![CDATA[1]]></rulegrouping> 
 <elementorder><![CDATA[5]]></elementorder> 
 <ruleowner><![CDATA[15137]]></ruleowner> 
 <startdate_date><![CDATA[3/9/2012]]></startdate_date> 
 <enddate_date><![CDATA[12/31/2099]]></enddate_date> 
 </row> 
 </content>

Example JSON File

[ 
   { 
     "actionmode": "A", 
     "consumerid": "15137", 
     "rulename": "LBI-5055", 
     "structurename": "CO_AU", 
     "elementname": "COMPANY", 
     "operand": "equal to", 
     "elementvalue1": "2001", 
     "elementvalue2": "", 
     "rulegrouping": 1, 
     "elementorder": 1, 
     "ruleowner": "15137", 
     "startdate": "2/23/2011", 
     "enddate": "12/30/2099" 
   }, 
   { 
     "actionmode": "A", 
     "consumerid": "15137", 
     "rulename": "LBI-5055", 
     "structurename": "CO_AU", 
     "elementname": "ACCOUNTING UNIT", 
     "operand": "equal to", 
     "elementvalue1": "901207", 
     "elementvalue2": "", 
     "rulegrouping": 1, 
     "elementorder": 2, 
     "ruleowner": "15137", 
     "startdate": "2/23/2011", 
     "enddate": "12/30/2099" 
   }, 
   { 
     "actionmode": "A", 
     "consumerid": "15137", 
     "rulename": "companyStringString1String2String3", 
     "structurename": "CompanyStringString1String2String3", 
     "elementname": "string3", 
     "operand": "within range of", 
     "elementvalue1": "060000", 
     "elementvalue2": "069999", 
     "rulegrouping": 1, 
     "elementorder": 5, 
     "ruleowner": "15137", 
     "startdate": "3/8/2012", 
     "enddate": "12/30/2099" 
   } 
 ] 

Required Syntax and Formatting

Position Column Description
1 ACTIONMODE

Indicates what you want the line item to do. Valid Values are:

  • D = Delete

  • A = Add

  • C = Change the existing Right Line item

  • U = Unknown (If the record corresponding to the item does not exist, change this value to A to add it. If you want to change the corresponding record, change this value to C).

2 USERORROLE The name of the User or Role.
3 RIGHTNAME Name of the Right
4 STRUCTURENAME

Name of the Structure.

Note: 

The structure must already exist in Reporting Services.

5 ELEMENTNAME

Name of the Element.

Note: 

The element must already exist in Reporting Services.

6 COMPARISON

What type of comparison you want performed on the element and value. Valid values are:

  • equal to

  • within range of

  • not equal to

  • less than

  • greater than

  • less than or equal to

  • greater than or equal to

  • contains

7 ELEMENTVALUE The element value upon which the comparison acts.
8 ELEMENTVALUE2 The second element value upon which the comparison acts upon. Valid for "within range of."
9 ELEMENTGROUP The groups within a structure. This value is required and must be a positive number. Allows for import of multiple elements. This value is the index of the element group.
10 ELEMENTORDER This value must be a positive number.
11 OWNER The name of the right owner. This value must be a valid User or Role.
12 STARTDATE

The start date should be in mm/dd/yyyy format.

Note: 

Both STARTDATE and ENDDATE are optional. If STARTDATE is empty, then ENDDATE must be empty. If both dates are given, STARTDATE should precede ENDDATE.

13 ENDDATE The end date should be in mm/ddy/yyyy format.