# Why some result of CityData is List[entity]?

Why one entity is a List Object? There are many such cases. They are in one level/one region/province.

CityData[{"Anqing", "Anhui", "China"}]
(* Entity["City", {"Anqing", "Anhui", "China"}] *)

CityData[{"Bangbu", "Anhui", "China"}]
(* {Entity["City", {"Bengbu", "Anhui", "China"}]} *)


• Please add text instead of screenshots so we can copy/paste/evaluate. I assume here that one of these is an entity, but the other is an entity class with one member. – Jason B. Jan 23 '18 at 15:46

That's an old design: if the input matches exactly the standard name, it will return the entity by itself. If the input is not a valid standard name, it will try to find the possible entities the input refers to. In the second case you could have asked without the region for example:

In[1]:= CityData[{"Bangbu", "China"}]

Out[1]= {Entity["City", {"Bengbu", "Anhui", "China"}]}


Of course, the answer would have been more than one if many cities have the same name, like with springfield cities:

In[2]:= CityData[{"springfield", "Wisconsin", "UnitedStates"}]

Out[128]= {Entity["City", {"Springfield", "Wisconsin", "UnitedStates"}],
Entity["City", {"SpringfieldStCroix", "Wisconsin", "UnitedStates"}],
Entity["City", {"SpringfieldMarquette", "Wisconsin", "UnitedStates"}],
Entity["City", {"SpringfieldJackson", "Wisconsin", "UnitedStates"}]}


In this last case I did input "springfield" with lowercase instead of uppercase to avoid matching the exact standardname for the first entity.