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: 

Doubt on Debugging Mode .....how to check the values are filling or not ?

kabil_g
Active Participant
0 Kudos

Hi friends,

                 I have 50000 content of records     from that 25000 number of record was wrong or

How to analyse that and resolve it.


15 REPLIES 15

krishna_k19
Contributor
0 Kudos

Hi ,

    Can u clarify your question .

you want whether the table is filling or not ? (or) half-of-the records are wrong.

Regards,

Krishna

kabil_g
Active Participant
0 Kudos

Example: 

1--> My sales order number is  wrong ( or ) sales order number alone correct "" remaining Contents are mismatching ""

2--> How to find the values filling or not

Former Member
0 Kudos

you can use watch point in debugging to stop at particular record.

If you want to stop at material 100 then create watch point and in condition give workarea-matnr = 100.It will stop when material 100 is reached.then you can analyse it.

0 Kudos

Hi Kabil ,

use watch point while debugging.

http://www.saptechnical.com/Tutorials/ABAP/Debug/Watchpoint.htm

Regards

srini

Former Member
0 Kudos

Hi kabil g!

If you are trying to view content of an internal table then double click on the internal table of your code section. And on the right side of screen, you will see the tablename, say 'ITAB'     .

Double click on the table, ITAB, or else manually type ITAB[] and click on it.

On clicking it, you will get the contents. Now double click on any one of COLUMN NAME (say, ebeln) to get it highlighted. Once highlighted, click on find symbol (binocular symbol) on the top menu bar.

Now write the value[s] for the column[s] which you need to find. And click ok. If the hit is successful, system will scroll down to the hit.

Regards,

Khushboo

0 Kudos

Hello Kabil,

The best way to handle this issue is to download the Internal table data to Excel. Filter the records based on the criteria.

Other way round is to create a similiar type internal table and move bad records to this internal table based on the criteria of identifying it as wrong records.

Regards

Suresh Nair

kabil_g
Active Participant
0 Kudos

Hi friends ,

                    My question is the 250000 record was wrong how to find that .

0 Kudos

how you are finding that 25000 records were wrong,

anyway some key should be there for wrong records.

move wrong records to some other internal table.

Based on that you can filter right ?

Former Member
0 Kudos

Hi kabil !

Please try this:

- Set a debugger on the line where you are using a logic/query to fill table, say itab.

Now, execute the program.

-> At the top, there will be a button 'Watchpoint' - click on that.

-> Write 'itab' on 'Variable' field.

-> Click on 'No Additional Condition'    

                    -> on 'Free Condition Entry' write: " lines( IT_MSEG ) >= 250000 "

-> To check the variables before 25000 (till data was correct), press F5 and note down the logic flow - i.e. note down values of vaiables, such as sy-subc - do this for first 5 correct records.

-> Now, set a break point at the statement immediately after endloop, and press F8.

So suppose your code is as below, set a breakpoint at line DELETE and press F8:

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

Loop at itab into wa.

perform logic.

endloop.

DELETE itab where field1 = INITIAL.

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

Loop will automatically stop at 250000 record (since you have set a watchpoint).

-> Now double click on the work-area WA and view the data, or any other condition value(say sy-subrc). Watch where the behavior pattern is changing, from this point on press F5 and keep checking, till you realize.

Regards,

Khushboo





former_member189845
Active Participant
0 Kudos

simple boss first find out the 250000 good records , obviously the rest 250000 will be wrong  

0 Kudos

Hi Sivaramakrishnan ,

   Approximately i say 250000 record was wrong.  how can i find that particular record

0 Kudos

Hi Kabil,

I can understand your concern, i am sharing you my way, which, i use to check any report on server where we are not allowed to debug.

We used to download entries from the table and download the report into EXCEL file . And then we apply VLOOKUP to find out the incorrect entries.

Sometimes it is the bestway to find out the actual errors among huge entries and also you can be sure that the specified values are not matching with the report values.

Regards,

Rahul Singh

Phillip_Morgan
Contributor
0 Kudos

Hello,

You could use watchpoint. This will normally stop when the value of watched variable has been changed. But you can do more: your wathcpoint can be a condition which  may help you find a specific record right when the condition arises.

Former Member
0 Kudos

Hi Kabil,

It is obvious that you are fetching data from tables using select query or BAPI.

So the data if used proper filters will pick correct data.

The only issue in the code arises when you do the read, append, insert, validations, corrections or calculation.

I will suggest instead of directly looking at the records for internal table into debugging, it is always better that you debug it step by step.

Even if the code is very big you being an ABAPer must be knowing at which point it should break to check particular internal table.

Once you analyse one record is giving an error then you will succeed in finding other errors as well.

After you get first error say at row 20000 then you can use watchpoint from that record and it will be easy for you.

Thankyou.

Best Regards,

Varun D.