cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Filter only numeric data - DTP

Former Member
0 Kudos
728

Hi,

Can I filter only numeric data for a field in a Data Transfer Process?

Regards.

Flávia.

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi Flavia,

You can apply filters on specific fields, Can u be for specific in your requirement?

Open DTp -> Click Filter -> Change Selection -> use <> keys to add the fields which u wanna filter on.

Cheers,

Sagar

Former Member
0 Kudos

Hi Sagar,

I don´t know why, but the option "Change Selection" is disabled. Do you have idea why this?

So, with this option I can filter only numeric datas from a characteristic?

Cheers,

Flávia.

Answers (4)

Answers (4)

Former Member
0 Kudos

Hello Flavia,

You can implement this by simply writing an ABAP routine at the DTP level.

Br,

H

Former Member
0 Kudos

Harish,

In the level of DTP where I put the ABAP code?

Regards.

Flávia.

ravi_chandra3
Active Contributor
0 Kudos

Hi Flavia,

Please once check the below screenshot.

and suppose if u need to write the code , then below is the code:

l_t_range-fieldname = 'give the corresponding IO name'.

l_t_range-sign = 'I'.

l_t_range-opt = 'EQ'.

l_t_range-low = 'here u have to assign the value '.

append l_t_range.

endif.

Hope you got it,

Regards,

RC

Former Member
0 Kudos

Hello Flavia,

As suggested by Ravi, you can write an ABAP routine in the DTP level to fulfill your requirement.

Br,

H

Former Member
0 Kudos

OK, I´m trying to write a abap code now, i wrote something like that:

     FIND REGEX '[A-Za-z]' IN SOURCE_FIELDS-/BIC/CA_1666.

     IF sy-subrc = 0.

          "contains letters

           RESULT = 0.

     ELSE. 

          "does not contain letters

     ENDIF. 

I´m thinking about put this code on the start routine in the transformation between the source and DSO.

This abap code is correct? In this case a will take and save only numeric datas in the /BIC/CA_1666 ?

Thanks a lot.

Flávia.

bmalyadri
Explorer
0 Kudos

Hi Flávia.

The filter works like the selections in the InfoPackage. You can specify single values, multiple selections, intervals, selections based on variables, or routines.

Choose Change Selection to change the list of InfoObjects that can be selected.

If the Infoobject is having data as combination of numarics and  alphamerics,

For ex : Object-A is having the values lik 1A23BZ5 ,  12345,  C34DF1 , 5656.

you need to filter as only having the numarics (Ex: 12345, 5656) so you have to write the ABAP routine based on Infoobject (Ex: Object-A).

I hope, you are trying to use the filters on Characteristic Infoobjects.

Regards

Malyadri

Former Member
0 Kudos

Yes, Malyadri. I´m trying to to filter only numerics datas from a characteristic.

Regards.

Flávia.

ravi_chandra3
Active Contributor
0 Kudos

Hi

If the numeric data is from the characeristic then you can implement the filter in this case.

Regards,

RC

Former Member
0 Kudos

Hi Ravi,

I´m trying to make this filter. When a looked de list of characeristics I can´t find the field. Key fields can´t be filtered?

Tanks a lot.

Flávia.

ravi_chandra3
Active Contributor
0 Kudos

Hi flavio,

Can you explain what IO have you created ? and what data type have you assigned to it.

Regards,

RC

ravi_chandra3
Active Contributor
0 Kudos

Hi

Filters are applied only on characteristic not on keyfigure.

Regards,

RC

amanda1807
Newcomer
0 Kudos

hi,

  I had this issue to me recently.

 I think it might because you didn't change the source DSO setting,like this.

amanda1807_0-1726038609638.png

  Change the field selection peoperties to -> selection possible, and refresh ,that we can find the filter in the DTP.