IBM MAINFRAME HELP & SUPPORT FORUMS
Technical Forums for IBM Mainframe Applications like COBOL, JCL, CICS, DB2, FileAid, DFSORT, Endevor, Xpediter, CoolGen, CA-7&11, AbendAid, IMS, IDMS, PL/I, MqSeries, SyncSort, Assembler, ChangeMan, Easytrieve, InterTest, REXX, CLIST etc...
 

IMS Database design

THIS IS AN ARCHIVE FORUM: CLICK HERE TO GO TO THE ORIGINAL TOPIC

 
       IBMMAINFRAMES.com - IBM Mainframe Support Forums Index -> IMS DB/DC
View previous topic :: View next topic  
Author Message
bindu



Joined: 02 Jun 2003
Posts: 1

Posted: Sat Aug 16, 2003 9:33 am    Post subject: IMS Database design  

Hello All,
I have the following segments:
1. CUSTOMER MASTER with the fields:
Customer Code CUMCUSCDE Alphanumeric 5 Primary Key
Customer Name CUMCUSNME Alphanumeric 30
Address CUMCUSADD Alphanumeric 30
City CUMCUSCTY Alphanumeric 30
Region CUMCUSREG Alphanumeric 2
Country CUMCUSCNT Alphanumeric 30
Telephone CUMCUSTEL Alphanumeric 15

2. ITEM MASTER :
with the following fields:
Field Description Name Type Size Remarks

Item Code ITMCDE Alphanumeric 5 Primary Key
Item Description ITMDES Alphanumeric 30
Price ITMPRC Numeric 9,2
Stock on Hand ITMSTK Numeric 6,0

3. SALES ORDER HEADER with the following fields
Field Description Name Type Size Remarks

Sales Order Number SOHORDNUM Alphanumeric 6 Primary Key
Sales Order Date SOHDT Date 10 Alternate Key
Customer Code SOHCUSCDE Alphanumeric 5
Order Status SOHORDSTS Alphanumeric 1

4. SALES ORDER TRANSACTION :
Field Description Name Type Size Remarks

Sales Order Number SODORDNUM Alphanumeric 6
Item Code SODITMCDE Alphanumeric 5
Quantity Ordered SODQTY Numeric 6



Can any body guide on how to design the database for this? We thought of going like this
customer master ->sales order header -> sales order transaction -> item master
But we were adviced not to go for this. But for 2 data bases one with customer master as root and another with item master as root.
But from item master we need to retreive item details once we give customer code. If we go for the above design how will we retrieve?
Can you please advice?
Thanks and Regards,
Bindu
Back to top  
maverick



Joined: 13 Nov 2003
Posts: 2

Posted: Thu Nov 13, 2003 10:43 am    Post subject:  

The 2nd idea is right . You will need to create 2 databases
1. customer master ->sales order header -> sales order transaction
2. item master

Once you get the customer code . You will have to go to the sales order transaction for that customer to know what that customer has ordered Then for each item code you will have to do a GU on the item master database to get the details .
Back to top  
b_ramu78



Joined: 29 Apr 2005
Posts: 1
Location: hyd

Posted: Fri Apr 29, 2005 3:48 pm    Post subject: to eliminate duplicate records thru INTERNAL SORT  

Hi Guys,

Good morning!

I have an quick deliverable to be made and i need your help in it as i do not have time to look in to books. ..


Can some give me the code to eliminate the Duplicate records through Internal sort ( Sort should be done thru cobol program ) or any mechanism using a Cobol program ..


Thanks in Advance!

Regards,
Back to top  
 
       IBMMAINFRAMES.com - IBM Mainframe Support Forums Index -> IMS DB/DC
Page 1 of 1
THIS IS AN ARCIVE FORUM IN READ ONLY MODE. IF YOU WANT TO ASK YOUR DOUBTS USE THE ACTUAL FORUM