How Do I Change Date-Time in form of text to Date and Time format

Dear great Minds,

Working with a SQL workbench, I have encountered Date coming in this format “2019-10-16T13:40:13”.

Please I am stuck on how I can separate this Date-Time field which comes in text format to:

  1. Date, then Time
  2. Split the single field into separate Date and Time fields, so that I am able to filter data fields according to Date.

I will appreciate immensely any help in this regards.
Thank you all.

Hey, TD.

This could depend on the SQL dialect you’re using, but treating as strings should work. For example, the code below should fetch all events in October 2019 from the table events.

SELECT *
  FROM event
 WHERE event_date LIKE '2019-10-%'
;

Thanks very much Bruno.
This meets my need.