Skip to Main Content

SQL Developer

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

acctno is null when displaying data

50980Mar 22 2006 — edited May 22 2006
Weird thing, have a table called accounts, with a primary key on acctno number(10), and some other fields. Note: Table is IOT

When I display the data when browsing the table I cannot see the acctno, but all other information, when I click on the row in the acctno field the value is displayed. I attempt to commit and it does not let me, a message displays that some other user has updated the record, and asks me to rollback. No other user is connected.

Here is the structure..

REM ACCOUNTS

CREATE TABLE ACCOUNTS
( "ACCTNO" NUMBER(10,0) NOT NULL ENABLE,
"CREATED_BY" VARCHAR2(30) NOT NULL ENABLE,
"CREATED_ON" DATE NOT NULL ENABLE,
"ACCT_TYPE_ID" NUMBER(22,0) NOT NULL ENABLE,
CONSTRAINT "ACC_PK" PRIMARY KEY ("ACCTNO") ENABLE
) ORGANIZATION INDEX NOCOMPRESS
ALTER TABLE ACCOUNTS ADD CONSTRAINT "ACCTNO_CHECK" CHECK (LENGTH(ACCTNO) = 10) ENABLE;

REM CERBERUS BUI_ACCOUNTS

CREATE OR REPLACE TRIGGER "BUI_ACCOUNTS"
before INSERT OR UPDATE of acctno on accounts
for each row
declare
-- local variables here
begin
IF NOT acct.valid_acct_num (:NEW.acctno) THEN
RAISE_APPLICATION_ERROR(-20001,'Acct Not Valid);
END IF;
end BUI_ACCOUNTS;

Let me know what you find. Note: there is a foreign key constraint on acct_type_id which I removed for simplicity.

Cheers.
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Jun 19 2006
Added on Mar 22 2006
12 comments
1,572 views