This invention discloses a method and
system for automated generation and optimization of
database table structures. The method specifically includes: receiving the user's backend project
source code; extracting a
semantic information network graph related to data persistence through static code scanning; inputting the
semantic information network graph into an intelligent
parsing engine to analyze code logic relationships and obtain index recommendation strategies and potential table structure design flaws; based on the index recommendation strategies and potential table structure design flaws, identifying sensitive fields and recommending
encryption or de-identification schemes to obtain a first table structure; performing automated
stress testing on the first table structure and adjusting the index strategy and partitioning scheme based on the test results; and optimizing the first table structure according to the adjusted index strategy and partitioning scheme to obtain a second table structure. This invention achieves intelligent generation and optimization of
database table structures, improving development efficiency, enhancing
maintainability, improving user experience, and ensuring
data security.