As the Web technology is progressing, XML (Extensible Markup Language) has become a new data exchange format for future Web mining and applications. Various XML middleware have been developed for transferring Web data stored in relational databases to XML documents enabling a uniform data searching technique. However, these developments are not efficient due to their using extra memory and database resources that lead to poor scalability in Web mining development. In this paper, we explore the research on building an efficient XML middleware for large-scale Web mining applications. Our approach is that if the XML structure can be properly embedded in the creation of relational content during XML middleware table construction, the data in the relational database could be retrieved with minimum amount of memory and database resources. The results of our approach will be analyzed and comparisons with related research will be made.