title: Error changing datetime format from python to SQL Server
body: <p>I am using Python to load my data into SQL Server. I would like to change the format of <code>ScheduledStartDate</code> from &quot;20-APR-2021 09:00:00 AM&quot; to &quot;2021-04-20 09:00:00&quot;</p>
  <pre><code>df['ScheduledStartDate'] = pd.to_datetime(df['ScheduledStartDate'])
  df['ScheduledStartDate'] = df['ScheduledStartDate'].dt.strftime('%Y-%m-%d %H:%M:%S')
  </code></pre>
  <p>However, I get this error</p>
  <blockquote>
  <p>The conversion of a nvarchar data type to a datetime data type resulted in an out-of-range value.</p>
  </blockquote>