created auto generating sql