code to search the common attribute in datasets