Page 1 of 1

SQL Error: conversion error from string "0"

Posted: 03.02.2009, 10:18
by louis
Hallo,
I have this error message:
SQL Error: conversione error from string "0". Error Code: -413. Overflow occurred during datatype conversion.

I use delphi 5 with zeos 6.6.4.

I need to use a TTimeField that can have 0.00 time inside but when I try to save the query, I have the error above in unit ZDbcInterbase6Utils.

I understand this is because the time is empty but what I do to solve this problem?

Thanks.

Posted: 03.02.2009, 10:52
by mdaems
Hi,

Can you please file a bug report on the bug tracker? ( http://zeosbugs.firmos.at/ ) Please attach a minimal project showing the error and the script needed to set up the database.

Mark

Posted: 03.02.2009, 16:12
by louis
mdaems wrote:... Please attach a minimal project showing the error and the script needed to set up the database.
Hi Mark,

while I prepared the example I have uncovered where I mistook. :oops:
During create table in database I assigned wrong default, see wrong code:

Code: Select all

CREATE TABLE CEDOLINI
(
  ID_CEDOLINO Integer NOT NULL,
  GIORNO1 Time DEFAULT 0 NOT NULL, <--- ERROR
  PRIMARY KEY (ID_CEDOLINO)
);
but the line correct is:

Code: Select all

  GIORNO1 Time DEFAULT '00.00' NOT NULL, <--- CORRECT!
Thanks