Table of Contents

Search

  1. Preface
  2. Introducing Reference 360
  3. Getting started with Reference 360
  4. Manage system reference data
  5. Manage reference data sets
  6. Manage code lists
  7. Manage code values
  8. Manage crosswalks
  9. Import data
  10. Manage hierarchies
  11. Manage attributes
  12. Manage workflows
  13. Manage jobs
  14. Reference 360 REST API
  15. Glossary

Reference 360

Reference 360

Import value mappings

Import value mappings

Imports value mappings into a crosswalk.

POST request

To import value mappings into a crosswalk, submit a POST request with the following URI:
/rdm-service/external/v1/import
The request contains form-data with two parameters:
file
Specify a CSV file that contains the code value attributes. The columns specified depend on your data model. The CSV starts with two header rows, followed by the data rows.
For example, you might have the following code values:
sourcePKey,_from.id.sourcePKey,_to.id.sourcePKey sourcePKey,_from.id.sourcePKey,_to.id.sourcePKey AF_AFG,AF,AFG AL_ALA,AL,ALA ALB_ALB,ALB,ALB DZ_DZA,DZ,DZA AS_ASM,AS,ASM
importSettings
Specify the file specific configuration and container details.
The
importSettings
includes the following attributes:
Field
Type
Description
delimiter
String
Delimiter used to separate values. Value must be
ASTERISK
,
CIRCUMFLEX
,
COLON
,
COMMA
,
PIPE
,
SECTION
,
SEMICOLON
,
SPACE
, or
TAB
.
textQualifier
String
Symbol used to indicate where a text begins and ends. Value must be
DOUBLE_QUOTE
,
SINGLE_QUOTE
, or
NO_QUOTE
.
codepage
String
Code page used for the export file. Value must be
UTF8
.
dateFormat
String
Format used for dates. Use one of the following formats:
  • DE
    . For dd.mm.yyyy format.
  • ISO
    . For yyyy-mm-dd format.
  • US
    . For mm/dd/yyyy format.
containerType
String
Type of asset that contains value mappings. Value must be
crosswalk
.
containerId
String
The ID of the crosswalk to which you want to import value mappings.
You can find the ID of assets in
Reference 360
or use REST APIs to retrieve the IDs. For more information, see Asset IDs.
startingRow
String
Line number from which to start importing data. By default, all rows are imported.

POST response

The response contains the details of the import job.
The following table describes the attributes in the response:
Field
Type
Description
jobId
String
ID of the job.
state
String
Status of the job. Values are
CREATED
,
INPROGRESS
,
COMPLETED
,
SUSPENDED
,
FAILED
,
STOPPED
,
QUEUED
or
WARNING
.
startTime
Number
Time, in milliseconds, when the job started.
numOfRecordsProcessed
Number
Number of records processed.
numOfRecordsFailed
Number
Number of records that failed to be imported.
numOfRecordsSucceeded
Number
Number of records successfully imported.

POST example

To import value mappings into a crosswalk, you might use the following request:
POST https://use4-mdm.dm-us.informaticacloud.com/rdm-service/external/v1/import HTTP/1.1 Content-Type: multipart/form-data; boundary=6o2knFse3p53ty9dmcQvWAIx1zInP11uCfbm IDS-SESSION-ID: XXXXXXXXXXXXXXXXXXXXXX --6o2knFse3p53ty9dmcQvWAIx1zInP11uCfbm Content-Disposition: form-data; name=file; filename=import-value-mappings.csv --6o2knFse3p53ty9dmcQvWAIx1zInP11uCfbm Content-Disposition: form-data; name=importSettings Content-Type: application/json;charset=UTF-8 { "delimiter":"COMMA", "textQualifier":"DOUBLE_QUOTE", "codepage":"UTF8", "dateFormat":"ISO", "containerType":"CROSSWALK", "containerId":"9ab3201990a54dcdc86f53AB", "startingRow":null } --6o2knFse3p53ty9dmcQvWAIx1zInP11uCfbm--
The CSV file might contain the following header rows and data rows:
sourcePKey,_from.id.sourcePKey,_to.id.sourcePKey sourcePKey,_from.id.sourcePKey,_to.id.sourcePKey AF_AFG,AF,AFG AL_ALA,AL,ALA ALB_ALB,ALB,ALB DZ_DZA,DZ,DZA AS_ASM,AS,ASM
The following sample response shows the status of the import job:
{ "jobId": "dd1b2018cb47cef99f8d0f43", "state": "INPROGRESS", "startTime": 1561367377428, "numOfRecordsProcessed": 100, "numOfRecordsFailed": 25, "numOfRecordsSucceeded": 75 }

0 COMMENTS

We’d like to hear from you!