cancel
Showing results for 
Search instead for 
Did you mean: 

fox -> add 1 to a null ratio

Former Member
0 Kudos

HI all,

I want to create a Fox formula which adds 1 to a ratio.

However this ratio is null (0).So, the record is not read and the ratio stays null.

Do you have a solution for my problem?

Thanks

Benjamin

Accepted Solutions (1)

Accepted Solutions (1)

ravikanth_indurthi
Active Contributor
0 Kudos

Hi Benjamin,

I think you can write a code in Ur transformation End routine.

Can U give more details.

Rgs,

I.R.K

Former Member
0 Kudos

My real problem is i can't read the combinaison if they are null.

When the Planning Sequence is executed, the first function generates the combinations and the secound has to change one ratio but as you can see in the message : 0 records read....

307 characteristic combinations generated 

 Planning function Generate all combinaison Country ( ZVER_AL02_COMB0 executed without errors 

 307 records read, 0 generated, 0 changed, 0 deleted 

 Planning function Ouverture tous pays ( ZVER_AL02_FORM01 ) executed without errors 

 0 records read, 0 generated, 0 changed, 0 deleted

formule :

DATA COUNTRY TYPE ZCOUNTRY.

FOREACH COUNTRY.

{ZAFFECT, COUNTRY} = 1.

ENDFOR.

Former Member
0 Kudos

Try removing country from fields to be changed (its not required there anyways as I see). Modify the formula as below (just 1 statement).

= 1.

Former Member
0 Kudos

same problem

0 records read, 0 generated, 0 changed, 0 deleted

thanks for trying

Former Member
0 Kudos

There is one more thing you can try - I have seen sometimes FOX does not create records when it does not read any records; but it does if all characteristics are marked 'to be changed'. See if doing that works for you; make sure there is no FOREACH loop in the code - you can use FOREACH IN SELECTION or FOREACH IN VARIABLE though, i think.

Let me know if that works.

Former Member
0 Kudos

Yes that works.

Thank you very much Mayank Gupta

I use FOREACH ... IN SELECTION.

Answers (0)