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: 

Cluster Fields in Transparent Tables.

amit_khare
Active Contributor
0 Kudos

I want to view the data stored in CLUSTD field of MONI table (in HEX Format), by converting to viewable format.

How can I do that?Also whats the procedure for storing data in such fields?

1 ACCEPTED SOLUTION

Former Member
0 Kudos

Hi Amit,

***************************************************

1. Table MONI field Clustd , contains RAW DATA

SO THE FIRST THING IS TO KNOW WHICH KIND OF DATA

IE. FIELDS, INTERNAL TABLE ETC.

IT CONTAINS.

***************************************************

This can be known via IMPORT Command.

Sample Program is:

-


DATA : CDIR LIKE TABLE OF CDIR WITH HEADER LINE.

*----


IMPORT META DATA

IMPORT DIRECTORY INTO CDIR FROM DATABASE MONI(DB)

ID 'SYSEVENT20041008074601'.

BREAK-POINT.

just look into internal table CDIR, it contains 3 fields.

1 SY-DATUM -- FIELD

2. SY-UZEIT --- FIELD

3. V_SYSTEM_EVENT_TAB -- TABLE

2. NOW TO GET DATA U CAN AGAIN USE IMPORT COMMAND

DATA : MYDATE TYPE SY-DATUM.

IMPORT SY-DATUM TO MYDATE FROM DATABASE MONI(DB)

ID 'SYSEVENT20041008074601'.

BREAK-POINT.

3. JUST TAKE CARE OF

A: DB

B: SYSEVENT20041008074601

A and B should be in your moni table.

4. for the 3rd field, V_SYSTEM_EVENT_TAB

I don't know what is the related structure.

(im still searching for it)

otherwise we can import it in the same way,

by declaring an internal table of the related

structure.

HOPE THIS HELPS.

Regards,

Amit Mittal.

2 REPLIES 2

Former Member
0 Kudos

Hi Amit,

***************************************************

1. Table MONI field Clustd , contains RAW DATA

SO THE FIRST THING IS TO KNOW WHICH KIND OF DATA

IE. FIELDS, INTERNAL TABLE ETC.

IT CONTAINS.

***************************************************

This can be known via IMPORT Command.

Sample Program is:

-


DATA : CDIR LIKE TABLE OF CDIR WITH HEADER LINE.

*----


IMPORT META DATA

IMPORT DIRECTORY INTO CDIR FROM DATABASE MONI(DB)

ID 'SYSEVENT20041008074601'.

BREAK-POINT.

just look into internal table CDIR, it contains 3 fields.

1 SY-DATUM -- FIELD

2. SY-UZEIT --- FIELD

3. V_SYSTEM_EVENT_TAB -- TABLE

2. NOW TO GET DATA U CAN AGAIN USE IMPORT COMMAND

DATA : MYDATE TYPE SY-DATUM.

IMPORT SY-DATUM TO MYDATE FROM DATABASE MONI(DB)

ID 'SYSEVENT20041008074601'.

BREAK-POINT.

3. JUST TAKE CARE OF

A: DB

B: SYSEVENT20041008074601

A and B should be in your moni table.

4. for the 3rd field, V_SYSTEM_EVENT_TAB

I don't know what is the related structure.

(im still searching for it)

otherwise we can import it in the same way,

by declaring an internal table of the related

structure.

HOPE THIS HELPS.

Regards,

Amit Mittal.

Former Member
0 Kudos

first, check the MONI, pay attention to two fields RELID, SRTFD. you should at least to know what the value of these two fields, for the entry you want to read in MONI.

Then call import like this:


DATA: INDXKEY LIKE MONI-SRTFD. 
data: WA_MONI type MONI.
data: it_cdir type standard table of CDIR.
INDXKEY  = 'XXX2'
IMPORT DIRECTORY INTO it_CDIR FROM DATABASE MONI(XXX1) ID INDXKEY TO WA_MONI.

XXX1 is RELID, belong to the entry which you want to read from MONI.

XXX2 is SRTFD, belong to the entry which you want to read from MONI.

Then it_CDIR store the info about the data export to MONI.

assume this table content like this:


NAME     OTYPE  FTYPE  TFILL  FLENG 
----------------------------------- 
F1         F      C      0      4 
TAB1       T      C      17     4

Means it export a field F1 and internal table TAB1

According to the above result, then import the data like following:


data: F1(4) type C.
data: TAB1  type standard table of CHAR4.

INDXKEY  = 'XXX2'
IMPORT F1   = F1 
       TAB1 = TAB1 FROM DATABASE MONI(XXX1) ID INDXKEY 
       TO WA_MONI.

If you want to achieve it dynamically, should using CL_ABAP_XXXX class to construct some dynamic data definite according to the CDIR result from IMPORT DIRECTORY.

Hope it will be helpful.

thanks