React. How to set a column value that depends on another column

I’m new to development. I’m just studying the TS JS reaction. I can’t handle it. I get it from the employee’s database. Columns name, city of residence and city of employment. It is necessary not to display the city of employment if the city of the device coincides with the column of residence. I can’t pull out the data to put in variables for comparison.

I read the documentation, tried useState, useReducer and a lot of other things, but nothing…….

<div className={""}>
            <Table
                className={"settings-table"}
                columns={[{caption: Translate.NAME, accessorKey: 'name'},
                    {caption: Translate.CITYOFRESIDENCE, accessorKey: 'city_residence'},
                    {caption: Translate.CITYOFEMPLOYMENT, accessorKey: 'city_employment'},
                ]}
                data={this.state.clients.data}
                }}/>
</div>