Subject | [IBO] Overflow - using a domain Numeric(18,4) WITH SCRIPT THIS TIME! |
---|---|
Author | Anthony |
Post date | 2001-06-07T07:47:25Z |
Here is the script i mentioned
When I try to
CREATE DOMAIN BOOLEAN AS SMALLINT
DEFAULT 0
CHECK (VALUE IN (0,1));
CREATE DOMAIN BOOLEAN AS SMALLINT
DEFAULT 0
CHECK (VALUE IN (0,1));
CREATE DOMAIN CURRENCY AS NUMERIC(18, 4);
CREATE DOMAIN CURRENCY AS NUMERIC(18, 4);
/* Table: PAYMENTS, Owner: SYSDBA */
CREATE TABLE "PAYMENTS"
(
"PAYMENTID" INTEGER NOT NULL,
"TXREF" INTEGER,
"METHOD" VARCHAR(20) NOT NULL,
"AMOUNT" "CURRENCY",
"NUMBER" VARCHAR(20),
"EXPIRY" VARCHAR(8),
"STARTDATE" VARCHAR(8),
"AUTHORISATION" VARCHAR(16),
"ISSUENUMBER" CHAR(4),
"PRINTED" "BOOLEAN",
"PAID" "BOOLEAN",
"CURRENCY" VARCHAR(20),
"RATE" NUMERIC(18, 4),
"TENDERED" "CURRENCY",
PRIMARY KEY ("PAYMENTID")
);
SET TERM ^ ;
/* Triggers only will work for SQL triggers */
CREATE TRIGGER "PAYMENT_PAYMENTIDGEN_INSB" FOR "PAYMENTS"
ACTIVE BEFORE INSERT POSITION 0
AS
BEGIN
IF (NEW.PAYMENTID IS NULL) THEN NEW.PAYMENTID = GEN_ID
(PAYMENTS_PAYMENTIDGEN, 1);
END
^
COMMIT WORK ^
SET TERM ;^
When I try to
> > view/accesss this via a TDBEdit via a TDatasource pointing at adbedit
> > ClinetDataset, and the value is > 0 all that is display in the
> > is {overflow} - Que passe' and how do I resolve this./* Domain definitions */
CREATE DOMAIN BOOLEAN AS SMALLINT
DEFAULT 0
CHECK (VALUE IN (0,1));
CREATE DOMAIN BOOLEAN AS SMALLINT
DEFAULT 0
CHECK (VALUE IN (0,1));
CREATE DOMAIN CURRENCY AS NUMERIC(18, 4);
CREATE DOMAIN CURRENCY AS NUMERIC(18, 4);
/* Table: PAYMENTS, Owner: SYSDBA */
CREATE TABLE "PAYMENTS"
(
"PAYMENTID" INTEGER NOT NULL,
"TXREF" INTEGER,
"METHOD" VARCHAR(20) NOT NULL,
"AMOUNT" "CURRENCY",
"NUMBER" VARCHAR(20),
"EXPIRY" VARCHAR(8),
"STARTDATE" VARCHAR(8),
"AUTHORISATION" VARCHAR(16),
"ISSUENUMBER" CHAR(4),
"PRINTED" "BOOLEAN",
"PAID" "BOOLEAN",
"CURRENCY" VARCHAR(20),
"RATE" NUMERIC(18, 4),
"TENDERED" "CURRENCY",
PRIMARY KEY ("PAYMENTID")
);
SET TERM ^ ;
/* Triggers only will work for SQL triggers */
CREATE TRIGGER "PAYMENT_PAYMENTIDGEN_INSB" FOR "PAYMENTS"
ACTIVE BEFORE INSERT POSITION 0
AS
BEGIN
IF (NEW.PAYMENTID IS NULL) THEN NEW.PAYMENTID = GEN_ID
(PAYMENTS_PAYMENTIDGEN, 1);
END
^
COMMIT WORK ^
SET TERM ;^
--- In IBObjects@y..., "Jason Wharton" <jwharton@i...> wrote:
> I see nothing else here.
>
> Jason Wharton
> CPS - Mesa AZ
> http://www.ibobjects.com
>
>
> ----- Original Message -----
> From: "Anthony" <anthonydcruze@y...>
> To: <IBObjects@y...>
> Sent: Wednesday, June 06, 2001 9:19 AM
> Subject: [IBO] Overflow - using a domain Numeric(18,4)
>
>
> > Hi, below is the script for one of my tables. When I try to
> > view/accesss this via a TDBEdit via a TDatasource pointing at a
> > ClinetDataset, and the value is > 0 all that is display in the
dbedit
> > is {overflow} - Que passe' and how do I relove this.