# How to populate TYPE in the dbt Docs?

**URL:** <https://discourse.getdbt.com/t/how-to-populate-type-in-the-dbt-docs/5399>\
**Category:** Help\
**Tags:** dbt-docs, dbt-cloud\
**Created:** [November 22, 2022, 9:35pm UTC](https://discourse.getdbt.com/t/how-to-populate-type-in-the-dbt-docs/5399 "2022-11-22T21:35:04Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![boopbeep](https://avatars.discourse-cdn.com/v4/letter/b/f6c823/32.png) [@boopbeep](https://discourse.getdbt.com/u/boopbeep)\
**Post date:** [November 22, 2022, 9:35pm UTC](https://discourse.getdbt.com/t/how-to-populate-type-in-the-dbt-docs/5399/1 "2022-11-22T21:35:04Z")

</div>

How do I fill in the column’s data type in the generated dbt docs? I referred to this [column\_types | dbt Developer Hub](https://docs.getdbt.com/reference/resource-configs/column_types) but that’s only for seed file and doesn’t seem to work for models. I tried using CAST in the table’s transformation code but TYPE is still blank when I generate the docs afterwards…

---

<div class="post-metadata">

**Author:** ![jaypeedevlin](https://sea2.discourse-cdn.com/flex020/user_avatar/discourse.getdbt.com/jaypeedevlin/32/638_2.png) [@jaypeedevlin](https://discourse.getdbt.com/u/jaypeedevlin)\
**Post date:** [November 23, 2022, 4:37am UTC](https://discourse.getdbt.com/t/how-to-populate-type-in-the-dbt-docs/5399/2 "2022-11-23T04:37:19Z")

</div>

dbt gets the type information by querying the model when the docs are generated. Was the model run before the docs were generated?

If so, I wonder if it could be that the adapter doesn’t support it, which warehouse are you on?

---

<div class="post-metadata">

**Author:** ![joellabes](https://sea2.discourse-cdn.com/flex020/user_avatar/discourse.getdbt.com/joellabes/32/3980_2.png) [@joellabes](https://discourse.getdbt.com/u/joellabes)\
**Post date:** [November 23, 2022, 5:18am UTC](https://discourse.getdbt.com/t/how-to-populate-type-in-the-dbt-docs/5399/3 "2022-11-23T05:18:45Z")

</div>

It is possible to set data types on columns for models, sources etc as well: [columns | dbt Developer Hub](https://docs.getdbt.com/reference/resource-properties/columns)

However as @jaypeedevlin said, you shouldn’t need to - dbt should check your database’s information\_schema or equivalent. Have a look at your logs when you run `dbt docs generate` - if dbt can’t access the information schema with the account it’s using, you may need to grant that user permissions, as shown by an error like this (Redshift example):

> Warning: The database user “dbt\_joel” has insufficient permissions to query the “svv\_table\_info” table. Please grant SELECT permissions on this table to the “dbt\_joel” user to fetch extended table details from Redshift.

---

<div class="post-metadata">

**Author:** ![reachbharathan](https://avatars.discourse-cdn.com/v4/letter/r/ee7513/32.png) [@reachbharathan](https://discourse.getdbt.com/u/reachbharathan)\
**Post date:** [December 3, 2024, 1:03pm UTC](https://discourse.getdbt.com/t/how-to-populate-type-in-the-dbt-docs/5399/4 "2024-12-03T13:03:34Z")

</div>

In my case, I have the datatype in my metadata.json, but it is not getting rendered in my dbt docs serve.  
example

```auto
"HOLIDAY_DENSITY": {
            "name": "HOLIDAY_DENSITY",
            "description": "Description Not Available",
            "meta": {},
            "data_type": "DOUBLE",
            "constraints": [],
            "quote": null,
            "tags": []
        }

```

---

<div class="post-metadata">

**Author:** ![ann8ty](https://sea2.discourse-cdn.com/flex020/user_avatar/discourse.getdbt.com/ann8ty/32/5535_2.png) [@ann8ty](https://discourse.getdbt.com/u/ann8ty)\
**Post date:** [April 8, 2025, 7:13pm UTC](https://discourse.getdbt.com/t/how-to-populate-type-in-the-dbt-docs/5399/5 "2025-04-08T19:13:25Z")

</div>

@reachbharathan I had this problem too. All of the code gen code used data\_type and it didnt appear in the docs. If you change the field to “type”, then they appear in the docs. Seems the dbt modules is out of sync.

---

<div class="post-metadata">

**Author:** ![reachbharathan](https://avatars.discourse-cdn.com/v4/letter/r/ee7513/32.png) [@reachbharathan](https://discourse.getdbt.com/u/reachbharathan)\
**Post date:** [April 9, 2025, 4:13am UTC](https://discourse.getdbt.com/t/how-to-populate-type-in-the-dbt-docs/5399/6 "2025-04-09T04:13:25Z")

</div>

Yes @ann8ty , I was also able to fix it up, but didn’t update here, thanks .  
yes its seems the document is not updated.
