cancel
Showing results for 
Search instead for 
Did you mean: 

duplicate rows

0 Kudos

hi,

can anyone tell me how to filter out duplicate rows....

thanks

karthick

Accepted Solutions (0)

Answers (2)

Answers (2)

0 Kudos

Karthick,

It is possible that you have a bad or are missing a table join in your query as well. If you add in this join it will perform better than a distinct.

-Sam

0 Kudos

hi,

thanks for your replies......suppose there is an xml query giving duplicate rows in output...is there any BLS action blocks to elimate those duplicate rows.....

thanks

karthick

Former Member
0 Kudos

Hi Karthik,

There is one <b>Distinct Value Extrator Action</b> in BLS under XML functions.

You can try that

Regards

Muzammil

Former Member
0 Kudos

Ahamed

<b>Distinct Value Extrator Action</b> is just only for extracting the distinct values in <b>one column</b>, NOT the rows in the whole XML dataset.

Karthik

I think u need to make some combined or custom actions to get distinct rows from the XML which will lead exhausting hands with logical complexity (by using Repeater, Conditional, Assignment to Local variables, Resetting etc), since there is no such defined single Action Block in BLS for getting distinct rows from an XML Dataset

Regards

Som

0 Kudos

hi som,

this will work when the number of columns is fixed.in my case the months(jan' 07,feb' 07....)are going to be the columns.in future the no. of columns is going to differ....so how we can do with that.....

thanks

karthick

Former Member
0 Kudos

In SQL, use "select DISTINCT..." instead of just "select"

If you are in BLS there is a distinct value extractor you can use, or if you have a repeater action you can type something like this in the XPATH

query.response{/bapi_name/table/item[not FIELDNAME = preceding-sibling::item/FIELDNAME]}

Hope this helps

Nick

Former Member
0 Kudos

Hi,

In Sql u can use like this "select distinct(fieldname) from table name"

it will retrive only non duplicate records

Pls give points if u satisfy with answer

Thanks

Ramesh