Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
尝试将日期时间列设置为默认值NOW()或CURRENT_TIMESTAMP时出现错误:
ALTER TABLE temp MODIFY COLUMN EntryDate EntryDate datetime DEFAULT NOW()
首先,相同的查询在 MySQL 上的本地实例上运行良好,但在 Azure 上的 ClearDB 上触发相同的查询时却无法正常工作。它会标记一个错误,说明 EntryDate 的默认值无效。