-Replace self-made SQL commands with the index functions -Use the "sql_sequence" table to get max values