クエリを確認してください。
SELECT DATE_FORMAT( CAST( CONCAT( table.date, " ", table.time ) ) , '%p' )
FROM table AS table
Error:
[hash]1064 - You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '), '%p') FROM exp_visitorsday as vd LIMIT 0, 30' at line 2
次の場合にこのクエリを試しました。
SELECT DATE_FORMAT( CAST( CONCAT( table.date, " ", table.time ) as datetimecol ) as datetimecol, '%p' )
FROM table AS table
SELECT DATE_FORMAT( CAST( CONCAT( table.date, " ", table.time ) as datetimecol ), '%p' )
FROM table AS table
サンプルデータ:
table.date => 01-08-2013
table.time => 10:00 AM
クエリを実行するには? このクエリの問題点は何ですか?