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: 

How to change a Views field and combine two different existing column

erkanakin
Participant
0 Kudos

Hello ,

I'm creating a view and linking 3 tablesinside the view . And I would like to have additional field in the same view , that I can fill according to an ABAP rule and join two fields information in this field.

Is it possible to do this change in the view or should I create a new table adding all view fields and an additional field and fill  this table according to a logic in exit?

Thanks in advance for help

Erkan

1 ACCEPTED SOLUTION

Former Member
0 Kudos

you have the three tables and if you want to add the two new fields !

is your two new fields are already exists any of the tables? if yes you can adjust it in the same view!

if not you need to adjust the two fields any of the tables to store the data in database level.

let me know if you have the different issue

6 REPLIES 6

Former Member
0 Kudos

you have the three tables and if you want to add the two new fields !

is your two new fields are already exists any of the tables? if yes you can adjust it in the same view!

if not you need to adjust the two fields any of the tables to store the data in database level.

let me know if you have the different issue

0 Kudos

Hello Kiran ,

Let me explain with an example ,

I have Following fields

First Record
Table A field date1 empty
Table B field date2 30.01.2014

Second Record

Table A field date1 25.01.2014

Table B field date2 30.01.2014

First record

Then I want to fill the date from Table B field date2 30.01.2014   because Table A don't have date

Second Record

I want to fill the date from Table A field date1 25.01.2014

So basicly I want to write in aview field , if Table A date is empty take it from Table B

Thanks ,

Erkan

0 Kudos

Hi,

if you want to do it automatically you need to write the small program to update the field in table A from table B field.

the view is useful only to update the data manually!

create the view with the two tables and update the field manually !

View ( Join Table A and Table B )

TABLEA-FIELD1           TABLEA-FIELD2                  TABLEB-FIELD1             TABLEB-FIELD2

0 Kudos


Hello Kiran ,

Thanks for reply , do you mean , it is not possible to create a user entry field in View .

As I understand as View fields are referencing to tables , this is always filling from Table fields referenced. How should we fill the data manually in view ?

0 Kudos

I m saying that we can create the user entry with the view ( read, write , delete).

- By inner join the two tables you can maintain the entry in view, it will automatically updates and can view the details in tables

please check the doc below

Database Views (SAP Library - BC - ABAP Dictionary)

0 Kudos

Hi,

You can also create a view with 3 fields ( 1 date field in table A, 1 in  table B & derived one in one of the tables ). Both the date fields of table A & table B will be hidden ( Mark the field as 'H' during maintenance view creation .

To fill the derived field (3rd filled), ;you need to write logic in events in TMG.

Regards,

DPM