connects to SQL.