Within the framework of flexible querying of possibilistic databases, based on the fuzzy set theory, this chapter focuses on the case where the vocabulary used both in the querying language and in the data is hierarchically organized, which occurs in systems that use ontologies. We give an overview of previous works concerning two issues: firstly, flexible querying of imprecise data in the relational model; secondly, the introduction of fuzziness in hierarchies. Concerning the latter point, we develop an aspect where there is a lack of study in current literature: fuzzy sets whose definition domains are hierarchies. Hence we propose the concept of hierarchical fuzzy set and present its properties. We present its application in the MIEL flexible querying system, for the querying of two imprecise relational databases, including user interfaces and experimental results.