cancel
Showing results for 
Search instead for 
Did you mean: 

my endroutine code is not executing ...not able to debug too!!!

Former Member
0 Kudos

hi experts,

       we have written endroutine in transformations between psa and dso . it seems there is already some code in end routine .we added our requirement code

at bottom.

  Q1.when we execute dtp its not populating  data for keyfigures we wanted to populate data ..dnt know why??

  Q2. we tried to debug...kept braeak point in my endroutine code and executed dtp in debugging mode but we pointer is 

        not yet all going to my code  not able debug too,dnt know why??

rest of the code which created by other consultants is in oops(its migrated code ---from bw3.5 to BI 7.0)

is it causing any problem ????

Q4  can we  add different set of codes in endroutine(for different fields)  ??

please help me sort it out ..

thanks in advance ,

hari

Accepted Solutions (0)

Answers (2)

Answers (2)

Former Member
0 Kudos

am really thank full to all for all your valuable inputs..

in transformation in some routine there coded breakpoint...may be for this  reason debugger is stopping at that coded breakpoint only..........

for mapping ...still cant understan why should we give where "

ll Target Fields (Independent of Active Rules) indicator. " is serving my purpose ...

we have implemented start routine at cube avoided endroutine at dso ....

former_member186445
Active Contributor
0 Kudos

1.

the fields you want to populate in the end routine need to be mapped in the transformation, you can use a constant.

2.

to debug transformation, go to 'display generated program' and set the breakpoint there. next time you execute the dtp it will stop there

3.

no

4.

yes

Former Member
0 Kudos

thank you so much for your reply tibollo...

1.for end routine we go with out mapping na ...we select option "all target fields(independant of active rules)".... if i use constant mean how does it append values populated from endroutine ????

2.debugging..even i have tried in same way ...but its not going to tat code.there is coded breakpoint in old code ..pointer is going there not moving to my code....

ravi_chandra3
Active Contributor
0 Kudos

Hi hari,

For expert routine we go without mapping, for start and end routine we have to map and if you are using constant , then there is no need to have routine.

we can apply break point in 2 ways like double clicking on the code or by  writing <break-point> statement at the first line.

Hope you got it,

Regards,
RaviChandra

Former Member
0 Kudos

hi ravi,

"Change Update Behavior of End Routine to set the All Target Fields (Independent of Active Rules) indicator. "

it self designed for endroutine ...but you are saying tat it will be used only for expert routines???

and  if i am mapping mean how should i map??with wat kyf ?? becuase i am getting data from quantity kyf wit different conditions..................

ok i will with quantity qyf what rule type should i choose ??
do wann me select  routine ???that would be feild level routine na ???

debugging---tried in sames way ..but not working

pls help me to sort it

ravi_chandra3
Active Contributor
0 Kudos

Hi hari ,

Can u explain it further more ? I did not get you.

Rgards,

RaviChandra

Former Member
0 Kudos

Hi

Try this.

When you enter the debug mode and when you are able to see the earlier code, try to search your code in the debug mode and set a break-point manually.

Check the code for syntax errors. Also check whether you have written your code exactly  in the endroutine. There are someother classes and methods when you open the endroutine. I doubt you have written your code in someother class or method.

Regards

Murthy

Former Member
0 Kudos

have mentioned my code between

METHOD end_routine.
*=== Segments ===

     FIELD-SYMBOLS:
       <RESULT_FIELDS>    TYPE _ty_s_TG_1.

     DATA:
       MONITOR_REC     TYPE rstmonitor.

*$*$ begin of routine - insert your code only below this line        *-*
... "insert your code here

here i have inserted my code

*$*$ end of routine - insert your code only before this line 

no sytax error ...

there is coded break point...pointer going to that alone ..

ravi_chandra3
Active Contributor
0 Kudos

Hi hari,

What i got from your explanatio is that, you should not map any thing in the end routine. Is it what you are saying . This is wrong assumption. we should map some entries in the end routine , but where as in the expert routine we will map the same by using the code .

Note : In end routine, we have to map some of the IO manually and we need to populate the data for the remaining IO by using the condition .

Hope you got it,
Regards,
RaviChandra.

Former Member
0 Kudos

hi ravi,

i have involved in couple of endroutines implementation...

we always went without mapping and enabling below indicator .working fine...

"Change Update Behavior of End Routine to set the All Target Fields (Independent of Active Rules) indicator. "

you have suggested me to give mapping for kyf for which i am populating data through end routine..

....so am not sure with which field i should map and what ruletype should be assigned ???

ravi_chandra3
Active Contributor
0 Kudos

Hi babu,

Let me explain with an example , you have ds and dso . right now in the ds you have calday data and in the target you should have year , month fiscal year period .

ds                                               data target

calday      -----------------------------------   calday

amt          -----------------------------------   amt

                                                      calyear

                                                     calmonth

                                                     fiscalperiod

So in this case you have to write the routine to populate the data for the fields calyear , calmonth , fiscal period in the endroutine as shown below.

loop at result_package assigning <result_fields>.

read table itab into wa with key wa-calday = <result_fields>-calday.

  <result_fields>-calmonth = ---.

<result_fields>-fiscalperiod = --.

<result_fields>-calyear = ----.

  endloop.

so the data is populated based on the data present in the calday at the infoprovider . so for that you have to map the calday from ds to infoprovider.So here without mapping how will you achieve that .

Hope you not confused with it,

Regards,
RaviChandra

Message was edited by: Ravi Chandra

former_member185132
Active Contributor
0 Kudos

Hi,

If you use "all target fields(independant of active rules)" you do not need to specify individiual field-level Constant mappings.

Now about the breakpoint, as Mark explained earlier on this thread, "to debug transformation, go to 'display generated program' and set the breakpoint there. next time you execute the dtp it will stop there"

Entering a break-point by opening the End Routine will not work. You need to use Mark's approach.

Regards,

Suhas