Many techniques have been proposed to store and query XML data efficiently. One way achieving this goal is using relational database by transforming XML data into relational format. It is important to transform schema to preserve the content, the structure and the constraints of the semantics information of the XML document. Especially, key constraints are an important part of database theory. Therefore, the proposal technique has considered the semantics of XML as expressed by primary keys and foreign keys. And, the proposal technique can preserve not only XML data constraints but also the content and the structure and the semantics of XML data thru