Board index » delphi » INSERT DATE type

INSERT DATE type


2007-04-05 12:26:37 AM
delphi224
Hi! I am getting an overflow error for the MYDATE variable in this instruction:
INSERT INTO TEMP (CLIENTID,MYDATE,FLAG) VALUES (:MYCLIENT,:MYDATE,1);
the de{*word*81} shows that it tries to insert doing this:
INSERT INTO TEMP (CLIENTID,MYDATE,FLAG) VALUES (1,CAST ('01/13/2007' AS DATE),1);
but the de{*word*81} also shows MYDATE variable as 13/01/2007, why does it reverse the day and the month to insert?
MYDATE type is DATE
I'm in IB 7.5
 
 

Re:INSERT DATE type

Something's recursing somewhere, and it sounds like bugs in your
de{*word*81}.
--
Craig Stuntz [TeamB] ?Vertex Systems Corp. ?Columbus, OH
Delphi/InterBase Weblog : blogs.teamb.com/craigstuntz
All the great TeamB service you've come to expect plus (New!)
Irish Tin Whistle tips: learningtowhistle.blogspot.com
 

Re:INSERT DATE type

aleplgr writes:
Quote

Hi! I am getting an overflow error for the MYDATE variable in this
instruction:
INSERT INTO TEMP (CLIENTID,MYDATE,FLAG) VALUES (:MYCLIENT,:MYDATE,1);


the de{*word*81} shows that it tries to insert doing this:
INSERT INTO TEMP (CLIENTID,MYDATE,FLAG) VALUES (1,CAST ('01/13/2007'
AS DATE),1); but the de{*word*81} also shows MYDATE variable as
13/01/2007, why does it reverse the day and the month to insert?
MYDATE type is DATE I am in IB 7.5
There is no de{*word*81} for stored procs and triggers built into
InterBase. I assume you are using some third party tool that simulates
execution of the code and the third party de{*word*81} is in an infinitely
recursive loop. This is not an IB problem because IB is not being used
to debug the code.
--
Bill Todd (TeamB)
 

Re:INSERT DATE type

"Bill Todd" <XXXX@XXXXX.COM>writes:
Quote
aleplgr writes:


There is no de{*word*81} for stored procs and triggers built into
InterBase. I assume you are using some third party tool that simulates
execution of the code and the third party de{*word*81} is in an infinitely
recursive loop. This is not an IB problem because IB is not being used
to debug the code.

--
Bill Todd (TeamB)
Yes you are right, I am using SQL Manager
www.sqlmanager.net/en/products/ibfb/manager
I was missing one column in the INSERT, should be like this:
INSERT INTO TEMP (CLIENTID,MYDATE,FLAG,ID) VALUES (:MYCLIENT,:MYDATE,0,1);
So now I have an infinite loop, I am trying to find why...
 

Re:INSERT DATE type

aleplgr writes:
Quote

Yes you are right, I am using SQL Manager
www.sqlmanager.net/en/products/ibfb/manager
I was missing one column in the INSERT, should be like this:
INSERT INTO TEMP (CLIENTID,MYDATE,FLAG,ID) VALUES
(:MYCLIENT,:MYDATE,0,1); So now I have an infinite loop, I am trying
to find why...
It is SQLManager that is getting into an infinite loop then - executing a
simple insert statement in IB cannot do such a thing.
--
Wayne Niddery - Winwright, Inc (www.winwright.ca)
"Reality is that which, when you stop believing in it, doesn't go
away." ?Philip K.{*word*106}