ADABAS field with default Alfanumeric value

Product/components used and version/fix level:

ADABAS

Detailed explanation of the problem:

Hello, I appreciate some explanation about one curiosity related to STORE command.

In Oracle we have this feature below. Is there something similar in ADABAS? ( not system fields )
Oracle Default Value
A column can be given a default value using the DEFAULT keyword.
The DEFAULT keyword provides a default value to a column when the Oracle INSERT INTO statement does not provide a specific value.
The default value can be literal value, an expression, or a SQL Function, such as SYSDATE.

CREATE TABLE demo_tbl (
    salary number(8,2) DEFAULT 9500,
    hire_date DATE DEFAULT '01-JAN-2011' ,
    birthdate DATE DEFAULT SYSDATE
)

In my current case I´d like to set an initial value for a control field IN-STATUS ,
but I´m also considering to ignore this and consider that the first status is ’ ’ (blank), but I wonder if it is a good practice.

There is no ADABAS equivalent of the SQL DEFAULT, as close as you can come would be using an Adabas Trigger to set a default when storing a new record.

2 Likes

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.