cancel
Showing results for 
Search instead for 
Did you mean: 

Remote key by RecordId in JAVA API

Former Member
0 Kudos

Hi,

I want retrieve remotekey field value in JAVA API for my record in MDM.

I can able get RecordId by using RetrieveLimitedRecordsCommand.

does anybody plz suggest to get remotekey values based on RecordId .

Thank you,

Kiran

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi Kiran,

You can use RetrieveRecordsKeyMappingsCommand for retrieving the key mappings for all records.

Set the Session, Table Id and record Ids using the setRecordIds() method of RetrieveRecordsKeyMappingsCommand.

Execute the command and you can get the RecordKeyMapping array containing all the keys using RetrieveRecordsKeyMappingsCommand.getKeyMappings();

Hope this helps!!

Cheers,

Arafat

Former Member
0 Kudos

RetrieveRecordsKeyMappingsCommand command = new RetrieveRecordsKeyMappingsCommand(<connection>);

command.setSession(sessionId);

command.setTableId(tableId);

command.setRecordIds(recordIds);

try {

command.execute();

return command.getKeyMappings();

} catch (CommandException e) {

throw e;

}

Answers (0)