cancel
Showing results for 
Search instead for 
Did you mean: 

Saving Related Entities

Former Member
0 Kudos

Hello Experts,

                        I have created BuilHeader Entity as root and I am trying to create BuilStandardAddress by using create_releted_entity method.

I am Getting the instance for BuilStandardAddress but I am not getting the Address Guid corresponding to it. So , when I call Save it is not getting saved.

While creating relared entity I am passing Relationship name and child entity name . Do I need to explicitly create the Address guid or am making any mistake? Can any one please suggest the solution.

                                         Thanks In Advance.

    

Regards,

Santosh

Accepted Solutions (0)

Answers (3)

Answers (3)

Former Member
0 Kudos

Hi santhosh,

Is you problem only in UI or does it happen in Genil_bol_browser as well? You need to call Modify for the Related Entities, and while saving do call Commit() for that transaction after calling save().

krishnendu_laha
Active Contributor
0 Kudos

Hello,

I think GUID would be created through assigned class for that related object; what I see is in post you are only saving the transaction, please call 'commit' method to save in database.

Thanks

Krish

former_member214667
Contributor
0 Kudos

Hi Santosh,

Do you call BOL Core modify after calling create_related_entity? If not, you should do it and the GUID you need should get created.

Regards,

Shiromani

kavindra_joshi
Active Contributor
0 Kudos

The process is like this

a) When you create an entity, it is first available in the BOL layer.

b) To push the changes to GENIL , you have to use the CL_CRM_BOL_CORE=>MODIFY( ).

c) To persist the changes , you have to call Transaction handler , Save. The changes which are in the genil buffers ( as in step b) are then persisted.

Test the same in GENIL_BOL_BROWSER and put the breakpoints in the CREATE , MODIFY , SAVE methods in the GENIL. 

Regards,

Kavindra

VishnAndr
Active Contributor
0 Kudos

Hello, Santosh.

Address guid will be assigned during the save process. What do you mean under 'when I call Save'? How do you call this?

Please check also the process of creation through BOLs using tx. GENIL_BOL_BROWSER. There you can create root entity BuilHeader (give BP component on the first screen then choose New Root Object and give BP_CATEGORY at least). After you entered some information for BuilHeader press Children button and then find and click BuilStandardAddressRel. Then press Insert Entity button. As you'll see there is no guid for address yet. Enter at lest COUNTRY and then press Save All at the top row of buttons. After this the guid will be assigned.