A Qualitative Constraint Network (QCN) is a constraint graph representing problems under qualitative temporal or spatial relations. More formally, a QCN includes a set of entities and a list of qualitative constraints defining the possible scenarios between these entities. Qualitative constraints are expressed as disjunctions of binary relations capturing the (incomplete) knowledge between the involved entities. QCNs effectively represent various real-world applications, including scheduling and planning, configuration, and Geographic Information Systems (GIS). It is, however, challenging to elicit, from the user, the QCN representing a given problem. To overcome this difficulty in practice, we propose a new algorithm for learning, through membership queries, a QCN from a non-expert. Membership queries are asked to elicit temporal or spatial relationships between pairs of temporal or spatial entities. To improve the time performance of our learning algorithm, constraint propagation and ordering heuristics are enforced. The goal is to reduce the number of membership queries needed to reach the target QCN. We conducted several experiments on randomly generated temporal and spatial QCN instances to assess the practical effect of constraint propagation and ordering heuristics. The results of the experiments are encouraging and promising.