cancel
Showing results for 
Search instead for 
Did you mean: 

Advanced FindForm (Query by Node item elements)

former_member200567
Active Contributor
0 Kudos

Hi, experts,

     I can make filters by root elements in Advanced findForms,

     but I don't know how to make filters by node elements.

     Like this example image below,

     I want to search back by the node item.

     Is there any documentation about advanced findforms?

     Any help is appreciated.

Regards,

May T.

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

I think that if the item is extendable in the BO extension, you can add additional fields in the item node, and then add these additional fields in the search area using the extensebility explorer

former_member200567
Active Contributor
0 Kudos

Hi, Alessandro,

     This is my own custom BO not a Standard SAP bo. I can't even make the search field for item node for my own BO.

     I can filter the OWL for the root node. But I can't filter back from the item node.

Regards,

May T.

Former Member
0 Kudos

I think you should add these fields as query parameters in your query definition on the UI. (Try to see and analyze the standard Activity OWL)

HorstSchaude
Product and Topic Expert
Product and Topic Expert
0 Kudos

Hello May T.

Maybe this is related to your question reg. the Overview nodes.

The QueryByElement which is created by the SDK for every node in the BODL is restricted to the elements of the actual node.

If you need elements form othe rnodes, e.g. from the sub-node Item, you call the Query Builder and define a query with all elements from the resp. nodes you need.

For this query you should be able to

- Access the elements evenof the sub node

- Define filtes for this elements

HTH,

    Horst

former_member200567
Active Contributor
0 Kudos

Yes, that's it. I think I should do it that way. But unfortunately, I don't know where to start.

Can you please explain it in a little bit more in detail.

Regards,

May T.

HorstSchaude
Product and Topic Expert
Product and Topic Expert
0 Kudos

Hello May T,

Does this docu helps you?

Bye,

    Horst

former_member200567
Active Contributor
0 Kudos

Not very helpful, Horst, I have read it. I think it doesn't contain much about Advanced Filter for node item.

What I want to do is to search the database by every element in my BO including node elements.

Just to be clear for what I want.

     element companyID:ID;

          node product[0,n]{

               element productID:ID;

          }

Company     Product

C1                    P1

                        P2

                        P3

C2                    P1

                        P4

C3                    P1

                        P2

I can make the filter for the company id.

But I can't make the filter for the product id.

I want to get C1,C2,C3 when I search for the product id P1.

Regards,

May T.

HorstSchaude
Product and Topic Expert
Product and Topic Expert
0 Kudos

Hello May T,

So, do you know how to create one query with the elements form the Root node (e.g. companyID)AND the elements form the product node (e.g. productID)?

Bye,

   Horst

former_member200567
Active Contributor
0 Kudos

Yes, I know.

One query for company. That's easy. I will bind the query with the root node's QueryByElements.

And the same for the product with the product's QueryByelements??

Regards,

May T

HorstSchaude
Product and Topic Expert
Product and Topic Expert
0 Kudos

Good morning May T.

Not one query for company and another one for products but only one for both.

Let's say your BO looks like this

After activation choose "Create Query" in the context menu for this BO (that's the Query Builder)

Follow the next steps and adapt them to your use case:

Step 1: Define the name and the parent of the query node

Step 2: Define the elements which can be used as query parameters

Step 3: Define which elements shall occur in the node. Only 1.1 relationship; therefore not the ProductIds

Finally activate the BO. Now it contains the Overview node with the query which in turn contains the company ID and the product ID (and the amount).

Use this query in your UI for the DefaultSet.

HTH,

     Horst

former_member200567
Active Contributor
0 Kudos

Hi,  Horst,

     Thank you so much for your detail guidance.

     I will try it.

Regards,

May T.

former_member200567
Active Contributor
0 Kudos

Hi, Horst,

     I don't understand what you meant in Step3.

Regards,

May T

former_member200567
Active Contributor
0 Kudos

Hi, Horst,

     It is ok when I bind the OverView's QueryByElements with the Query.

     But when I put the root_ID for the selected query parameters and bind with a field in SearchParamters. A backend error occurs in the browser.

Regars,

May T.

HorstSchaude
Product and Topic Expert
Product and Topic Expert
0 Kudos

Hello May T.

Step 3 defines which fields form the query parameter will become part of the Overview node.

HTH,

    Horst

former_member200567
Active Contributor
0 Kudos

You wrote " Only 1.1 relationship; therefore not the ProductIds"


But you selected every check box.


Regards,

May T.

HorstSchaude
Product and Topic Expert
Product and Topic Expert
0 Kudos

Hello May T.

Got it.

The first column defines the query parameter -> all checked

The last column defines the Overview node -> only the CompanyID is checked because for any single hit of a company many the ProductIDs may be returned too

HTH,

    Horst

HorstSchaude
Product and Topic Expert
Product and Topic Expert
0 Kudos

Hello May T,

Is your /Root/DataList bound to the Overview node or the Root node of your BO?

In my test UI I bound it to the Overview node (so the result list is just the Overview node) and on selection of a line in this list I took the node ID of this line (which is the same as the real Root node ID) and triggered the BO Operation Read with this node ID.

HTH,

    Horst

Answers (0)