1. A computer-implemented method for generating a program for accessing a database, the method comprising: retrieving one or more structure query language (SQL) statements associated with one or more database-centric applications for accessing the database; generating a syntax tree based on the one or more SQL statements, the syntax tree identifying a data structure of an SQL statement of the one or more SQL statements; generating a petri net model based on the syntax tree and a schema for the database; generating an augmented petri net model, based on the petri net model, that enforces mutual exclusion properties of the petri net model for identifying a deadlock caused by the one or more database-centric applications for accessing the database; and generating the program based on the augmented petri net model, the program being configured to receive first transactions from the one or more database-centric applications, predict a deadlock, and provide second transactions to the database based on predicting the deadlock.