Jump to content

Send all contents from one table to another and converting text date to realdate


0o0o0

Recommended Posts

 

have two tables .. ones full of data.. and the other empty..

 

I want to move all from TABLE_A to TABLE_B..  while converting a text date to real DATE..

 

my guess...

$sql = "INSERT INTO TABLE_B SELECT col1, (STR_TO_DATE(col2, '%m/%d/%Y')) as col2, col3,col4,col5,col6 from TABLE_A ";

 

this does not work for me.. and the date does not convert.

 

see any errors?

 

( identical columns identical tables)

Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.