# How to define a model with constrained to just one entry?

**URL:** <https://forum.builder.io/t/how-to-define-a-model-with-constrained-to-just-one-entry/5171>\
**Category:** General\
**Created:** [March 14, 2024, 8:42am UTC](https://forum.builder.io/t/how-to-define-a-model-with-constrained-to-just-one-entry/5171 "2024-03-14T08:42:00Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![oemeran](https://avatars.discourse-cdn.com/v4/letter/o/4bbf92/32.png) [@oemeran](https://forum.builder.io/u/oemeran)\
**Post date:** [March 14, 2024, 8:42am UTC](https://forum.builder.io/t/how-to-define-a-model-with-constrained-to-just-one-entry/5171/1 "2024-03-14T08:42:00Z")

</div>

In my case I need to add a single “highlighted blog article”. I just need one sheet where i can reference exactly one blog article manually. I can do this with Data/Section Models, but I can add infinite amount of entries to this model, which I don’t want.

Is there a way to define a simple meta data like model?

---

<div class="post-metadata">

**Author:** ![manish-sharma](https://avatars.discourse-cdn.com/v4/letter/m/8797f3/32.png) [@manish-sharma](https://forum.builder.io/u/manish-sharma)\
**Post date:** [March 14, 2024, 10:51am UTC](https://forum.builder.io/t/how-to-define-a-model-with-constrained-to-just-one-entry/5171/2 "2024-03-14T10:51:04Z")

</div>

Hello @oemeran,

Welcome to the [Builder.io](http://Builder.io) forum post.

At the moment, there is no way to limit the content entries for models. However, you can utilize the Validation Hooks feature to prevent users from publishing another entry if the content length is 1.

> **[Using model validation hooks - Builder.io](https://www.builder.io/c/docs/validation-hooks)**
>
> Model validation hooks are a powerful feature of Builder that allows you to define custom validation logic for your model's content using JavaScript.

Furthermore, we strongly encourage you to submit a feature request at [Builder.io Ideas](https://ideas.builder.io/ideas/)

---

<div class="post-metadata">

**Author:** ![oemeran](https://avatars.discourse-cdn.com/v4/letter/o/4bbf92/32.png) [@oemeran](https://forum.builder.io/u/oemeran)\
**Post date:** [March 14, 2024, 12:32pm UTC](https://forum.builder.io/t/how-to-define-a-model-with-constrained-to-just-one-entry/5171/3 "2024-03-14T12:32:58Z")

</div>

Thanks for your reply. Very sad that we don’t have a solution for this very basic CMS feature.

I created an “idea” as you suggested. Anyone that comes across this issue, please leave a vote here: [Add a singleton global data model | Builder.io Ideas](https://ideas.builder.io/ideas/PROD-I-389)

---

<div class="post-metadata">

**Author:** ![manfe](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.builder.io/manfe/32/3681_2.png) [@manfe](https://forum.builder.io/u/manfe)\
**Post date:** [April 18, 2024, 7:32pm UTC](https://forum.builder.io/t/how-to-define-a-model-with-constrained-to-just-one-entry/5171/4 "2024-04-18T19:32:01Z")

</div>

I was not able to find Validation Hooks for data structure models.

Update: I know why… only _enterprise plans_ have it.

---

<div class="post-metadata">

**Author:** ![oemeran](https://avatars.discourse-cdn.com/v4/letter/o/4bbf92/32.png) [@oemeran](https://forum.builder.io/u/oemeran)\
**Post date:** [April 21, 2024, 11:35pm UTC](https://forum.builder.io/t/how-to-define-a-model-with-constrained-to-just-one-entry/5171/5 "2024-04-21T23:35:06Z")

</div>

Yup, I have the same problem 😓 I basically told my Product Owner that she should only ever add 1 entry, because I can not limit it. Very bad tbh.
