Design update - printing function, SQL Queries