I have lots of dictionary in one list. For example;
totalList = [
{'id': 1111, 'source': 'user_1', 'count_id': 10, 'description': 'aaaa'},
{'id': 1412, 'source': 'user_2', 'count_id': 5, 'description': 'bbbb'},
{'id': 5123, 'source': 'user_1', 'count_id': 10, 'description': 'aaaa'},
{'id': 1982, 'source': 'user_3', 'count_id': 7, 'description': 'bbbb'},
{'id': 3198, 'source': 'user_3', 'count_id': 7, 'description': 'bbbb'},
{'id': 1082, 'source': 'user_1', 'count_id': 10, 'description': 'aaaa'}
]
- The id's are always different.
- All keys are the same.
I want to get id's that have the same source, same count_id and same description values. In this example, I just need to get the id's. Output:
1111, 5123, 1082 same
1982, 3198 same
How can i achieve this?
Thanks.