Oracle Form Data Entry Sample

发布时间:2017-5-28 3:56:51 编辑:www.fx114.net 分享查询网我要评论
本篇文章主要介绍了"Oracle Form Data Entry Sample ",主要涉及到Oracle Form Data Entry Sample 方面的内容,对于Oracle Form Data Entry Sample 感兴趣的同学可以参考一下。

Oracle Form Data Entry Sample

I shared a data entry example form here in this post for Oracle Forms beginner developers, so that they may take an idea to how to develop a simple data entry form in Oracle Forms. The form can be fully modified.

Example is given for an emp table and other related tables. You can download Emp.fmb form from Google drive by clicking here 
Emp.Fmb Form

To run this form you would require some tables in Payroll schema, so create a user/schema with name Payroll and run the following script:

-- start
CREATE TABLE DESIG
(
  DNAME  VARCHAR2(60 BYTE)
);


CREATE TABLE DEPT
(
  DNAME  VARCHAR2(60 BYTE)
)
;


CREATE TABLE EMP
(
  ECODE     VARCHAR2(10 BYTE),
  ENAME     VARCHAR2(60 BYTE),
  DESIG     VARCHAR2(60 BYTE),
  DEPT      VARCHAR2(60 BYTE),
  ADDR1     VARCHAR2(60 BYTE),
  ADDR2     VARCHAR2(60 BYTE),
  CITY      VARCHAR2(30 BYTE),
  STATE     VARCHAR2(30 BYTE),
  PINCODE   VARCHAR2(6 BYTE),
  PHONE     VARCHAR2(30 BYTE),
  DOJ       DATE,
  DOR       DATE,
  DOP       DATE,
  PFNO      VARCHAR2(30 BYTE),
  ESINO     VARCHAR2(60 BYTE),
  BASIC     NUMBER(10)                          DEFAULT 0,
  HRA       NUMBER(10)                          DEFAULT 0,
  CONV      NUMBER(10)                          DEFAULT 0,
  MEDC      NUMBER(10)                          DEFAULT 0,
  BONUS     NUMBER(10)                          DEFAULT 0,
  TEL       NUMBER(10)                          DEFAULT 0,
  OTHA      NUMBER(10)                          DEFAULT 0,
  CL        NUMBER(3)                           DEFAULT 0,
  EL        NUMBER(5)                           DEFAULT 0,
  SL        NUMBER(3)                           DEFAULT 0,
  PFA       NUMBER(10)                          DEFAULT 0,
  TDS       NUMBER(10)                          DEFAULT 0,
  TDSMB     NUMBER(2)                           DEFAULT 0,
  ADVTOTAL  NUMBER(10)                          DEFAULT 0,
  ADVDED    NUMBER(10)                          DEFAULT 0,
  BANKAC    VARCHAR2(50 BYTE),
  FY        VARCHAR2(9 BYTE),
  CP        VARCHAR2(30 BYTE),
  FYCP      VARCHAR2(40 BYTE),
  ESI       NUMBER(10,2),
  TDSDED    NUMBER(10,2)
)
;


CREATE TABLE FYCPT
(
  FY    VARCHAR2(9 BYTE),
  CP    VARCHAR2(30 BYTE),
  FYCP  VARCHAR2(40 BYTE)
)
;


CREATE TABLE MNTRANS
(
  TRANID      NUMBER(10),
  TRANDATE    DATE,
  ECODE       VARCHAR2(10 BYTE),
  ENAME       VARCHAR2(60 BYTE),
  NOOFABS     NUMBER(3),
  NOOFWD      NUMBER(3),
  NETBASIC    NUMBER(10,2),
  NETCONV     NUMBER(10,2),
  NETMED      NUMBER(10,2),
  NETBONUS    NUMBER(10,2),
  NETTEL      NUMBER(10,2),
  NETHRA      NUMBER(10),
  OT_HRS      NUMBER(10),
  OT_HRSAMT   NUMBER(10,2),
  OT_SAL      NUMBER(10,2),
  OTHER_A     NUMBER(10),
  GRS_SAL     NUMBER(10,2),
  PFA         NUMBER(10),
  ESIA        NUMBER(10),
  TDS         NUMBER(10,2),
  ADVI        NUMBER(10),
  OTH_DED     NUMBER(10),
  NETPAYABLE  NUMBER(10,2),
  CLT         NUMBER(2),
  ELT         NUMBER(2),
  SLT         NUMBER(2),
  TL          NUMBER(2),
  CAA         VARCHAR2(1 BYTE),
  FY          VARCHAR2(9 BYTE),
  CP          VARCHAR2(30 BYTE),
  FYCP        VARCHAR2(40 BYTE),
  FOR_MNTH    VARCHAR2(20 BYTE),
  FOR_YEAR    NUMBER(4)
)
LOGGING 
NOCOMPRESS 
NOCACHE
NOPARALLEL
MONITORING;



SET DEFINE OFF;
Insert into DEPT
   (DNAME)
Values
   ('COMMERCIAL');
Insert into DEPT
   (DNAME)
Values
   ('MAINT & SUPPORT');
Insert into DEPT
   (DNAME)
Values
   ('SYSTEMS');
Insert into DEPT
   (DNAME)
Values
   ('OPERATIONS');
Insert into DEPT
   (DNAME)
Values
   ('QUALITY CONTROL');
Insert into DEPT
   (DNAME)
Values
   ('ACCOUNTS');
Insert into DEPT
   (DNAME)
Values
   ('PACKING & DISPATCH');
Insert into DEPT
   (DNAME)
Values
   ('ADMINISTRATION');
Insert into DEPT
   (DNAME)
Values
   ('STORE');
Insert into DEPT
   (DNAME)
Values
   ('MAINTENANCE');
Insert into DEPT
   (DNAME)
Values
   ('DESIGNING');
Insert into DEPT
   (DNAME)
Values
   ('PURCHASE & STORE');
COMMIT;

SET DEFINE OFF;
Insert into DESIG
   (DNAME)
Values
   ('AGM');
Insert into DESIG
   (DNAME)
Values
   ('CHIEF MANAGER');
Insert into DESIG
   (DNAME)