How to create nested dictionary for below input

Hi Team

How to create nested dictionary for below input

Input:

Thanks
Shaik

@shaik.muktharvalli1,

Dictionary only can have Key and value. What exactly you are trying/looking for here?

from each row data table

Kadapa is a key then values are yerraguntla and North

thanks
shaik

@shaik.muktharvalli1,

Declare a dictionary datatype (Dictionary<string, object>) variable with default value this New Dictionary(Of String, Object) From {} to initialize it.

image

Now in Assign activity assign the key values like this:

c

Replace hardcoded values to as per your requirement.

Before adding a key,value

image

After adding:

Hi @ashokkarale

I need output like —Kadapa yerraguntla North (In single line )

please help

@shaik.muktharvalli1 Like this?

image

@ashokkarale yes

output like —Kadapa yerraguntla North

@shaik.muktharvalli1,

Using dictionaryPerson("Kadapa") anywhere you required like in Log Message message will give you the expected result

@shaik.muktharvalli1

use for each row in datatable inside that use assign as below

dict(currentrow(0).ToString) = currentrow(0).ToString + " " + currentrow(1).ToString + " " + currentrow(2).ToString

1 Like

Hello,

thnx