cancel
Showing results for 
Search instead for 
Did you mean: 

Query in Distribution Model creation

Former Member
0 Kudos

Hello All,

we are trying to build a distribution logic based on the below criteria

first data object has the following node structure

DO1

node1

childnode1

-field1

-field2

childnode2

-field1

-field2

the second data object has the following structure

DO2

node1

-field1

-field2

-field3

from the above data object i need to send data for the second data object DO2 based on the childnode1 and childnode2 value in DO1, can any one give a solution like how to create dependencies and create a DM.

Thanks and Regards,

Venkatesh R

Accepted Solutions (1)

Accepted Solutions (1)

0 Kudos

Hi,

Go through the following steps:

Step1->Create associations(Complete/Partial as mentioned above)

(a)between child node1 of DO1and root node1 of DO2

(b)between child node2 of DO1and root node1 of DO2

Step2->Create a Distribution Model(say DM1) for DO1

Step3->Add a rule to this DM1 so that DO1 will be distributed

Step4->Add two dependencies by using defined associations

Step5->Activate the DM1

Regards,

Ashish

Answers (1)

Answers (1)

Former Member
0 Kudos

What is a DM:

[http://help.sap.com/saphelp_nwmobile71/helpdata/en/d7/b72038f2894541bff51cb7fdf25bef/content.htm]

How to create dependencies:

[http://help.sap.com/saphelp_nwmobile71/helpdata/en/2b/b148bab8224e6ca9b80225613d23e0/content.htm]

You will want to create a dependency from both the child nodes of DO1 to DO2. This can be done by opening up the two nodes and creating an association from the two nodes, to DO2 (SDOE_WB transaction -> navigate to the nodes)

Then you create a DM, and rules for distributing DO1.

Once you're done with that, create 2 dependencies for DO2 using the wizard. Use one association in each dependency (the wizard is quite intuitive)

Then activate the DM and go get some coffee!

Former Member
0 Kudos

I must add this:

The Association from Node1 and Node2 will require you to match fields of each node, to the KEY fields in the ROOT node of DO2.

Basically, this will tell which instances of DO2 are related to these nodes.

Another thing: If you don't have all the key fields of DO2 as fields in your Node1 and Node2 of DO1, you will have to create a 'Partial Association' instead of a complete one. In such a case, each row of Node1 or Node2 will correspond to multiple instances of DO2.

Edited by: Arjun Shankar on Nov 19, 2009 1:26 PM

Former Member
0 Kudos

Hi Arjun,

Thanks for your reply. I have created Partial Node association between DO1 and DO2. I have used this association in Dependencies.

I have created a rule and mapped which maps a field in DO1 and device attribute (User). But the data is not distributed. I have re checked my data and rule, everything is fine.

Suppose, If I use bulk rule, the data is distributed successfully.

Is it possible to debug my Distribution Model and Rule to know where I made mistake?

Thanks ,

Venkatesh R

Former Member
0 Kudos

The code that decides instance distribution is generated code and pretty is complicated.

The one thing that might be helpful is checking device subscriptions.

In Device Administration, you need to open up your device and click on 'View Subscription Details' in the 'Device Status' tab.

Here you can see which kind of instances will get sent to the device. For example, one of the texts could be:

"USER_AUTHORIZATION - LOGIN_NAME EQ ARJUN"

This is for the USER_AUTHORIZATION data object.

Similarly, your DO should have an entry with the right values.

Former Member
0 Kudos

Another thing: Have you checked if your rule is active? You need to activate it after doing an initial load.

Former Member
0 Kudos

Hi Arjun,

Thanks for your reply. All rules are active. Actually I have created 4 dependencies between data objects DO1 and DO2. Each dependency has dependency rule. Is there any restriction on creating dependencies between data objects?

Thanks,

Venkatesh R

Former Member
0 Kudos

A couple of questions:

1. Have you checked the device subscriptions I mentioned in my earlier post? What does it show?

2. Is the device enabled and have the DMSWCV assigned to it and is operational? < The answer to this one is probably yes, but just want to double check

Here is the thing with dependencies: If DO1 has the DM, and DO2 is dependent, the only thing the dependencies do are distribute DO2 instances. So the problem of DO1 not being distributed is because of DO1 subscriptions (because your rules are on DO1). So don't bother about the dependencies right now.

Former Member
0 Kudos

Hi Arjun,

Thanks for you reply.

1. Have you checked the device subscriptions I mentioned in my earlier post? What does it show?

>> Yes I have checked. It shows correct value in Distribution Rule Creteria(For example- E_CFGDAT_DTL - LANGAUGE EQ E, here I have mapped language field with Device attribute.

2. Is the device enabled and have the DMSWCV assigned to it and is operational? < The answer to this one is probably yes, but just want to double check

>> Yes. Device is enabled and assigned DMSWCV assigned.

DO1 has following node structure:

List

Details1

Details2

Details3

Details4

DO2 has following node structure(Only one node):

List

DO1 has a rule that maps user field <List> with user in device attribute. It works fine.

Here each <details> in DO1 has dependency with <List> in DO2. Here <List> node in DO2 has language field. So I have created dependency rule and mapped language field with langauge of Device attribute. These 4 dependency rules are not working. Please help on this.

Thanks,

Venkatesh R

Former Member
0 Kudos

I understand this: You have a rule on DO1 (which works fine and distributes DO1 instances correctly) and dependencieso n DO2 (which are not distributing DO2 instances for some reason).

Now your model is something like this:

Each of the 4 child nodes in DO1 has a partial association to the DO2s root (the missed key field is Language).

For each of these associations, there is one dependency which will map to a list of instances of DO2 for all languages, corresponding to each DO1 instance. Now you want to prune this list and only send the instance of DO2 for the device's language.

NOW: If you created the dependency after activating the rule on DO1 then the dependency and its rules will not work right away. You need to deactivate the rule on DO1 and activate it again.

What you need to do:

1. Deactivate the Rule on DO1.

2. Activate the rule on DO1 again.

Hopefully, that should fix it.

-


By the way, the correct way to distribute language specific data for anything is not via another data object, but via a child node.

Lets say, you have some data (which is language independent) and text corresponding to that data (which is language specific). The way you should ideally do it is:

1. Create a node as a child to the node containing the language independent data. Put the language specific data in this node (all languages)

2. Create an Extract association from the parent node to the child node, within the data object.

3. Use this Extract association to create an extract rule in the Distribution Model. The DOE will then pick the correct language data for each device and send only the child instances that correspond to the language of the device.

Former Member
0 Kudos

Hi Arjun,

Thanks a lot for understanding my exact requirement.

I have deactivated rule in DO1and activated again. Now only one dependency rule is working for <Details1> node. Dependency rules for other nodes are not working.

I have checked in subcribption data. Same values are there for 4 nodes(as E_CFGDAT_DTL - LANGAUGE EQ E).

Thanks,

Venkatesh R

sivasatyaprasad_yerra
Active Contributor
0 Kudos

I've some questions here. Based on that may be we can help you.

1. Does the Details2, Details3 and Details4 child nodes of DO1 contains data?

2. How did you know dependency rule is working only for <Details1> node? On which basis, this interpretation was done?

3. Do you have any relevant data in DO2 which satisfies Details2, Details3 and Details4 child nodes of DO?

Regards,

Siva.

Former Member
0 Kudos

Hi Siva,

Thanks for your reply.

1. Does the Details2, Details3 and Details4 child nodes of DO1 contains data?

>> Yes, Details2, Details 3 and Details4 contains data.

2. How did you know dependency rule is working only for <Details1> node?

>> After assigning this DMSWCV to a device, I got the relevant data for <Details1> in Outbound queue.

On which basis, this interpretation was done?

>> I have partial node association between DO1 and DO2

3. Do you have any relevant data in DO2 which satisfies Details2, Details3 and Details4 child nodes of DO?

>> Yes I have relevant data on DO2. If I create bulk depency rule instead of normal rule, i am getting the relevent data for all languages.

Thanks,

Venkatesh R

sivasatyaprasad_yerra
Active Contributor
0 Kudos

Dependency and Dependency rules are not considered while distributing DO1 instances. As per previous discussions, Details1, Details2, Details3 and Details4 are child nodes for DO1. So, if you are not getting Details2, Details3 and Details4 data then there is different problem.

1. Are you not getting data for Details2, Details3 and Details4 nodes?

2. Do you have any other rules on DO1 like Node filter rule?

3. Did you select "Not Downloadable" option in data object node screen for Details2, Details3 and Details4 nodes?

Former Member
0 Kudos

Hi Siva,

Thanks for your reply.

1. Are you not getting data for Details2, Details3 and Details4 nodes?

>> Yes. If I use bulk rule, i am getting the data.

2. Do you have any other rules on DO1 like Node filter rule?

>> Now I dont have any rule on DO2. But I need it in future,

3. Did you select "Not Downloadable" option in data object node screen for Details2, Details3 and Details4 nodes?

>> No.

Thanks,

Venkateh R

Edited by: Venkatesh Ranganathan on Dec 14, 2009 2:51 PM

sivasatyaprasad_yerra
Active Contributor
0 Kudos

Details2, Details3 & Details 4 are child nodes of DO1 right? If that is the case, you should be getting data even if you use rule which maps to device attribute or Bulk rule. It doesn't matter which rule you are using. There is some problem in understanding the model. Please upload document with the node details of DO1 and DO2 and rule, dependency details in a document. So, that we will get better understanding here.