Multiple _key parameters in xtk.session.Write method

Avatar

Avatar
Give Back 5
Level 3
marcinkacz
Level 3

Likes

19 likes

Total Posts

46 posts

Correct reply

2 solutions
Top badges earned
Give Back 5
Give Back 3
Give Back
Ignite 1
Validate 10
View profile

Avatar
Give Back 5
Level 3
marcinkacz
Level 3

Likes

19 likes

Total Posts

46 posts

Correct reply

2 solutions
Top badges earned
Give Back 5
Give Back 3
Give Back
Ignite 1
Validate 10
View profile
marcinkacz
Level 3

18-03-2019

Hi All,

I would like to use xtk.session.Write method, but with multiple _key parameters. My goal is to reconcile records by two values @someId and @email at the same time. I know how to use single _key:

var newInput = "<myTable xtkschema='cus:myTable' _operation='insertOrUpdate' _key='@someId' someId='somevalue1' email='email@domain.com' nextField1='next value 1' nextField2 = 'next value 2' />";

xtk.session.Write(newInput);

But what is a proper syntax for two _keys?

Are you able to help me?

Thank you,

Marcin

Accepted Solutions (1)

Accepted Solutions (1)

Avatar

Avatar
Establish
MVP
wodnicki
MVP

Likes

977 likes

Total Posts

1,096 posts

Correct reply

516 solutions
Top badges earned
Establish
Affirm 500
Contributor
Shape 1
Give Back 100
View profile

Avatar
Establish
MVP
wodnicki
MVP

Likes

977 likes

Total Posts

1,096 posts

Correct reply

516 solutions
Top badges earned
Establish
Affirm 500
Contributor
Shape 1
Give Back 100
View profile
wodnicki
MVP

18-03-2019

Hi,

The _key attribute is comma-delimited. Here:

xtk.session.Write("<myTable xtkschema='cus:myTable' _operation='insertOrUpdate' _key='@someId,@email' someId='somevalue1' email='email@domain.com' nextField1='next value 1' nextField2 = 'next value 2' />");

Thanks,

-Jon

Answers (1)

Answers (1)

Avatar

Avatar
Give Back 5
Level 3
marcinkacz
Level 3

Likes

19 likes

Total Posts

46 posts

Correct reply

2 solutions
Top badges earned
Give Back 5
Give Back 3
Give Back
Ignite 1
Validate 10
View profile

Avatar
Give Back 5
Level 3
marcinkacz
Level 3

Likes

19 likes

Total Posts

46 posts

Correct reply

2 solutions
Top badges earned
Give Back 5
Give Back 3
Give Back
Ignite 1
Validate 10
View profile
marcinkacz
Level 3

19-03-2019

It works, thank you very much!