'0.0' is not a valid timestamp.
'0.0' is not a valid timestamp.
I have a small application running with an MS Access DB witout problems
Now I try to upgrade to MySQL using the folowing script for table.
When opening my form with datagrid I get an error saying '0.0' is not a valid timestamp.
Where would I have to look to figure this out?
I have spend hours trying to figure out what could be wrong.
CREATE TABLE `tblsalary` (
`fldsalary_guid` varchar(50) NOT NULL,
`fldsalary_debit` double default '0',
`fldsalary_kredit` double default '0',
`fldsalary_saldo` double default '0',
`fldsalary_text` varchar(50) default NULL,
`fldsalary_user` varchar(50) default NULL,
`fldsalary_computer` varchar(50) default NULL,
`fldsalary_date` date default NULL,
`fldtimestamp` datetime default NULL,
PRIMARY KEY (`fldsalary_guid`),
UNIQUE KEY `fldsalary_guid` (`fldsalary_guid`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
Now I try to upgrade to MySQL using the folowing script for table.
When opening my form with datagrid I get an error saying '0.0' is not a valid timestamp.
Where would I have to look to figure this out?
I have spend hours trying to figure out what could be wrong.
CREATE TABLE `tblsalary` (
`fldsalary_guid` varchar(50) NOT NULL,
`fldsalary_debit` double default '0',
`fldsalary_kredit` double default '0',
`fldsalary_saldo` double default '0',
`fldsalary_text` varchar(50) default NULL,
`fldsalary_user` varchar(50) default NULL,
`fldsalary_computer` varchar(50) default NULL,
`fldsalary_date` date default NULL,
`fldtimestamp` datetime default NULL,
PRIMARY KEY (`fldsalary_guid`),
UNIQUE KEY `fldsalary_guid` (`fldsalary_guid`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
The problem was that you created TDateTimeField for the date data type. If you remove all constant fields (using Fields Editor) from the TUniQuery component and add them again, you will see that UniDAC creates TDateField for date data types. After this you can set formatting of the fields that you want.