# Link databes replaces entity?

**URL:** <https://community.fibery.io/t/link-databes-replaces-entity/9546>\
**Category:** Get Help\
**Created:** [September 7, 2025, 8:26am UTC](https://community.fibery.io/t/link-databes-replaces-entity/9546 "2025-09-07T08:26:49Z")\
**Posts on this page:** 14\
**Page:** 1

<div class="post-metadata">

**Author:** ![Eva\_Folch](https://sea2.discourse-cdn.com/flex020/user_avatar/community.fibery.io/eva_folch/32/11814_2.png) [@Eva\_Folch](https://community.fibery.io/u/Eva_Folch)\
**Post date:** [September 7, 2025, 8:26am UTC](https://community.fibery.io/t/link-databes-replaces-entity/9546/1 "2025-09-07T08:26:49Z")

</div>

Hi, Not sure what I’m doing wrong…and I hope I can explain it.. 😉

I have a “Project DB” and a “Line items DB”, when I create an Invoice in “Invoice DB” I do it with a button, but sometimes I have to add several Projects to the prepared invoice.

I tried a Rule that links the “line items” from the projects, when the Invoice relation is added, to Invoice DB (which is one to many One Project /One Invoice - Many Line Items).

Now, it works, but the rule is replacing the already linked “Line item”, how do I do it so that stays, so that it does modify what’s already there?

---

<div class="post-metadata">

**Author:** ![myg\_ge](https://sea2.discourse-cdn.com/flex020/user_avatar/community.fibery.io/myg_ge/32/12457_2.png) [@myg\_ge](https://community.fibery.io/u/myg_ge)\
**Post date:** [September 7, 2025, 3:51pm UTC](https://community.fibery.io/t/link-databes-replaces-entity/9546/2 "2025-09-07T15:51:17Z")

</div>

Hi Eva,

This may have something to do with the filters of your rule.

Would you like to have a look into this together?

Michael

PS: Did you try to ask your question to Fibery AI? 🙂

---

<div class="post-metadata">

**Author:** ![Eva\_Folch](https://sea2.discourse-cdn.com/flex020/user_avatar/community.fibery.io/eva_folch/32/11814_2.png) [@Eva\_Folch](https://community.fibery.io/u/Eva_Folch)\
**Post date:** [September 7, 2025, 7:03pm UTC](https://community.fibery.io/t/link-databes-replaces-entity/9546/3 "2025-09-07T19:03:20Z")

</div>

Ai did not work, basically told me to do what I was doing. This is my rule in my Invoices DB:

 ![25.09.07](https://us1.discourse-cdn.com/flex020/uploads/fibery/original/2X/a/aca465d94d20f793ec9aff8ff8a7e98c54bfad5f.jpeg)

---

<div class="post-metadata">

**Author:** ![myg\_ge](https://sea2.discourse-cdn.com/flex020/user_avatar/community.fibery.io/myg_ge/32/12457_2.png) [@myg\_ge](https://community.fibery.io/u/myg_ge)\
**Post date:** [September 7, 2025, 10:30pm UTC](https://community.fibery.io/t/link-databes-replaces-entity/9546/4 "2025-09-07T22:30:35Z")

</div>

1. Please help me better understand your terminology.

Initially I thought when you say “Line Items” you mean those line items that are on the invoice. What are those line items you actually mean, what’s their role?

Some real world example would help.

1. Is this how it is in your current data model?

Invoice can have 1 or many Projects

Invoice can have 1 or many Line Items

Project can have 1 or many Line Items

---

<div class="post-metadata">

**Author:** ![Eva\_Folch](https://sea2.discourse-cdn.com/flex020/user_avatar/community.fibery.io/eva_folch/32/11814_2.png) [@Eva\_Folch](https://community.fibery.io/u/Eva_Folch)\
**Post date:** [September 8, 2025, 8:13am UTC](https://community.fibery.io/t/link-databes-replaces-entity/9546/5 "2025-09-08T08:13:07Z")

</div>

Yes, it looks like this! Line items is a DB, they are the line items in the invoice, but I already create them when I do a quotation.

---

<div class="post-metadata">

**Author:** ![Chr1sG](https://sea2.discourse-cdn.com/flex020/user_avatar/community.fibery.io/chr1sg/32/3941_2.png) [@Chr1sG](https://community.fibery.io/u/Chr1sG)\
**Post date:** [September 8, 2025, 10:28am UTC](https://community.fibery.io/t/link-databes-replaces-entity/9546/6 "2025-09-08T10:28:09Z")

</div>

> [@Eva\_Folch](#):
>
> the rule is replacing the already linked “Line item”

When you use the `Link Line Items` action it should not unlink existing Line items that are already linked.  
If they are getting unlinked, you may want to check out the activity log for the Invoice to see what is going on.

---

<div class="post-metadata">

**Author:** ![Eva\_Folch](https://sea2.discourse-cdn.com/flex020/user_avatar/community.fibery.io/eva_folch/32/11814_2.png) [@Eva\_Folch](https://community.fibery.io/u/Eva_Folch)\
**Post date:** [September 8, 2025, 10:50am UTC](https://community.fibery.io/t/link-databes-replaces-entity/9546/7 "2025-09-08T10:50:08Z")

</div>

You mean the log from the rule? It says it works, but it just unlinks the last line item. If I do it manually, without a rule, just adding the Invoice relation to the line items it works, but I don’t manage with the rule.

 ![25.09.08](https://us1.discourse-cdn.com/flex020/uploads/fibery/original/2X/8/81824a8dce2a4035dc593ea4d0ceaac409866c64.jpeg)

---

<div class="post-metadata">

**Author:** ![Chr1sG](https://sea2.discourse-cdn.com/flex020/user_avatar/community.fibery.io/chr1sg/32/3941_2.png) [@Chr1sG](https://community.fibery.io/u/Chr1sG)\
**Post date:** [September 8, 2025, 10:57am UTC](https://community.fibery.io/t/link-databes-replaces-entity/9546/8 "2025-09-08T10:57:53Z")

</div>

I don’t see that the rule is unlinking anything.

I meant that you should check the activity log for the entity itself.

 ![image](https://us1.discourse-cdn.com/flex020/uploads/fibery/original/2X/f/f5cd42ad520e2b194b74d9b3b7e4c6adf1a788ff.png)

---

<div class="post-metadata">

**Author:** ![Eva\_Folch](https://sea2.discourse-cdn.com/flex020/user_avatar/community.fibery.io/eva_folch/32/11814_2.png) [@Eva\_Folch](https://community.fibery.io/u/Eva_Folch)\
**Post date:** [September 8, 2025, 11:15am UTC](https://community.fibery.io/t/link-databes-replaces-entity/9546/9 "2025-09-08T11:15:52Z")

</div>

ah ok! thanks for your patience.

Indeed, it seems to unlink the last line item.

 ![25.09.08](https://us1.discourse-cdn.com/flex020/uploads/fibery/original/2X/7/75616ef199893f6e9a6c29696504ba2ad568fa04.jpeg)

---

<div class="post-metadata">

**Author:** ![Chr1sG](https://sea2.discourse-cdn.com/flex020/user_avatar/community.fibery.io/chr1sg/32/3941_2.png) [@Chr1sG](https://community.fibery.io/u/Chr1sG)\
**Post date:** [September 8, 2025, 1:14pm UTC](https://community.fibery.io/t/link-databes-replaces-entity/9546/10 "2025-09-08T13:14:32Z")

</div>

Thanks.  
Can you share a screenshot of the rule (as it currently is) and a screenshot of the activity log with the action details fully expanded.  
Thx

---

<div class="post-metadata">

**Author:** ![Eva\_Folch](https://sea2.discourse-cdn.com/flex020/user_avatar/community.fibery.io/eva_folch/32/11814_2.png) [@Eva\_Folch](https://community.fibery.io/u/Eva_Folch)\
**Post date:** [September 8, 2025, 1:54pm UTC](https://community.fibery.io/t/link-databes-replaces-entity/9546/11 "2025-09-08T13:54:55Z")

</div>

this is the rule.

> [@Eva\_Folch](#):
>
> ![25.09.07](https://us1.discourse-cdn.com/flex020/uploads/fibery/original/2X/a/aca465d94d20f793ec9aff8ff8a7e98c54bfad5f.jpeg)
> 
> 25.09.072364×1122 128 KB

And you mean this activity from the rule? :

 ![25.09.08](https://us1.discourse-cdn.com/flex020/uploads/fibery/original/2X/8/83569042a3c599e178e40656d4252db62aa693be.jpeg)

---

<div class="post-metadata">

**Author:** ![Chr1sG](https://sea2.discourse-cdn.com/flex020/user_avatar/community.fibery.io/chr1sg/32/3941_2.png) [@Chr1sG](https://community.fibery.io/u/Chr1sG)\
**Post date:** [September 8, 2025, 2:07pm UTC](https://community.fibery.io/t/link-databes-replaces-entity/9546/12 "2025-09-08T14:07:26Z")

</div>

Yes, assuming that’s showing the whole rule, and yes, but please expand all levels (for at least one of the runs)

---

<div class="post-metadata">

**Author:** ![Eva\_Folch](https://sea2.discourse-cdn.com/flex020/user_avatar/community.fibery.io/eva_folch/32/11814_2.png) [@Eva\_Folch](https://community.fibery.io/u/Eva_Folch)\
**Post date:** [September 8, 2025, 2:12pm UTC](https://community.fibery.io/t/link-databes-replaces-entity/9546/13 "2025-09-08T14:12:22Z")

</div>

![25.09.08](https://us1.discourse-cdn.com/flex020/uploads/fibery/original/2X/2/23fd3c31cfa246913e9462ce73096ea07aa46723.jpeg)

---

<div class="post-metadata">

**Author:** ![Chr1sG](https://sea2.discourse-cdn.com/flex020/user_avatar/community.fibery.io/chr1sg/32/3941_2.png) [@Chr1sG](https://community.fibery.io/u/Chr1sG)\
**Post date:** [September 8, 2025, 2:39pm UTC](https://community.fibery.io/t/link-databes-replaces-entity/9546/14 "2025-09-08T14:39:06Z")

</div>

I can’t reproduce this.  
Are there any other rules that would affect the Invoice db?
