Symbol database: faster implementation. Ticket: #4494