The SQL diagnostics area is a set of information maintained by the database manager about the SQL statement that was most recently run. It can be accessed from your program by using the GET DIAGNOSTICS SQL statement.