In this paper we propose an approach based on visual language parsing for guaranteeing the integrity of data produced during the editing process of maps. According to our approach, constraints are expressed by using high-level data model, such as OMT-G, and converted in a properly visual language grammar. From such a grammar, a parser able to identify incorrect aggregation of spatial data input is automatically generated. The grammar formalism also allows us to associate suitable semantic actions with productions in order to perform automatic corrections of inconsistent input data, error recognition and visualization, prompting actions for error recovery.