sql script, sidebar