Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

Please let me know to construct a custom table as per below requiremnt

Former Member
0 Kudos

Dear Friends

can any one please let me know hot to create a custom table as below

-


| outpatient |

|employeeno | class | startdate | enddate | spouse |1stchild | 2nchild| Rate | amount|

My FO wants to enter in the SM30 as above ......i.e he wants to have spouse ,1st child and 2nd child under one group........so he asking me to make as one group

and give a heading as outpatient.........similary i have to give for in patient.

Please could any one tell is it possible.

regards

syamala...

2 REPLIES 2

Former Member
0 Kudos

Hi

Create a Dataelement with single CHAR field with description OUTPATIENT and attach this data element to a DOMAIN with length 1 type CHAR and define the values for this domain as below

1 - Spouse

2 - 1st Child

3 -2nd Child

Now create a table with the following fields

Employee No - CHAR 8 or NUMC 8 data type

Outpatient -Single char

Class - CHAR type

Start Date -DATS data type

End date - DATS data type

Rate -CURR field wih 15 length and 2 decimals

Amount - Curr field wih 15 length and 2 decimals

<b>Reward points for useful Answers</b>

Regards

Anji

Former Member
0 Kudos

Steps to Creating domains, Data Elements, Tables

To give you the steps for creating table:.

There are two approach in creating a table.

1. Bottom-up approach

2. Top-down approach.

Both are valid and you can choose which approach is suitable for you. I always use the bottom-up approach. Here are the steps to create the tables with this approach.

1. SE11 will take you to the DDIC and enter the name of the new table to be created. Let us say Zname. Click create.

2. Enter the short discription of the table and enter the field of the table. If it is primary key and you have to check the box.

3. Enter the data element and double click it, you will be asked to save and will take you to data element discription page. Enter the short discription of the data element and enter the information of domain like the length of field and type of field.

4. If you wanted to use the existing domain then its fine, or else, you have to create one. Enter the domain name in the data element page and double click it. Page will ask to save and jump to domain creation page.

5. In the domain page, you have to save the information which you have already given in the data elements page and check it. Before going to data element page, you have to activate the domain.

6. Go to data element page and save, check and activate.

7. Go to main table page and save, check, and activate.

8. Also, you have to save the technical settings of the table.

The table is now ready for operation. You can use it in your program or you can use it to enter information.

Check table: It is the table which will have all the information about the Foreign keys which are the primary keys in the check table.

It can be created by creating the foreign key from the main table. Click foreign key in the main table and it will take you to a page which will ask for table name and field to which foreign key relation has to be associated. Enter the information and you can create the check table automatically.

SM30 is used for maintenance of the table, that is to realease the errors occured during the creation of the table.

create 1 data element with Outpatient and its domain as Patient datatype Char DATA LENGTH 1. in the value table of the Domain enter as

1 SPouse .

2 1stChild .

3 2nd Child

so the table fields

Employeeno 8 digit (CHAR)

Class 10 digit (CHAR)

Startdate 10digit(DATUM)

endatate 10digit(DATUM)

outpatient 1digit (C)-> Domian as 3 vaules

Rate 4digit (CURY)

Amount 15digit(CURR) referrnce Rate.

Reward points if it is usefull .

Girish