cancel
Showing results for 
Search instead for 
Did you mean: 

CHETAB In eCATT

Former Member
0 Kudos

Hi All,

I would like to know how to use the CHETAB command in eCATT. I am new to eCATT and what I tried is:

1. Created a new script

2. Went to patterns

3. Took CHETAB

4. Gave the table name (My own table name)

5. Gave '*' for the key field

6. Gave an field value which was there in the table.

When the value I gave was in the first row of the table, (ie, when we go to se11 and execute the table), the script passes. If the value is any other (but it is there in the third or fourth row in the table), the script fails. I would like to know how to deal with this situation. It is necessary to check in the tables as well, to test whether the values got into the table is correct right?

Accepted Solutions (0)

Answers (3)

Answers (3)

Former Member
0 Kudos

Hello Jubish,

CHETAB command is used for checking the database entries as the name suggests. In simple terms, it does the comparison between the database table value and the value specified by you in the command interface. If match happens, success log. And if not then error log.

There are recommendations from SAP on use of this command like not to specify blank value for key fields n all.

Specifying asterisk will serve the purpose provided you are not leaving any of KEY fields EMPTY. Fill each of the key field by asterisk for which you don’t know the values.

As you know what are you trying to verify from the database, try to give exact value for comparison possibly.

SAP Online help for CHETAB command -

http://help.sap.com/saphelp_erp2004/helpdata/en/7b/d6313b06bfaa74e10000000a114084/content.htm

PS If the answer solves your query, do reward the points to everyone responding.

Regards

Former Member
0 Kudos

HI Jubish,

CHETAB is most useful when you already have the values of Key fields of the table in check.

Giving '*' will fetch the first row of that table always, which is not desirable generally.

You can give '*' only when that particualr field is not a very important key field.

E.g. When you do a CHETAB on table VBAP. Then, ideally you should give the value of VBELN and POSNR and then check for any other field value for validation. In this case, if there is only a single row for that particular VBELN, then you can give '*' in POSNR field.

Hope,it will help you to understand the use of CHETAB.

Thanks & Regards,

Sasmita

Former Member
0 Kudos

Hi,

Could you please be a bit more elaborate on this. I didn't get it fully.

thanking you, .. ...

Former Member
0 Kudos

HI Jubish,

CHETAB is most useful when you already have the values of Key fields of the table in check.

Giving '*' will fetch the first row of that table always, which is not desirable generally.

You can give '*' only when that particualr field is not a very important key field.

E.g. When you do a CHETAB on table VBAP. Then, ideally you should give the value of VBELN and POSNR and then check for any other field value for validation. In this case, if there is only a single row for that particular VBELN, then you can give '*' in POSNR field.

Hope,it will help you to understand the use of CHETAB.