# usage of this inside model

**URL:** <https://discourse.getdbt.com/t/usage-of-this-inside-model/7177>\
**Category:** Help\
**Created:** [March 8, 2023, 7:17am UTC](https://discourse.getdbt.com/t/usage-of-this-inside-model/7177 "2023-03-08T07:17:35Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![karrajan](https://avatars.discourse-cdn.com/v4/letter/k/a6a055/32.png) [@karrajan](https://discourse.getdbt.com/u/karrajan)\
**Post date:** [March 8, 2023, 7:17am UTC](https://discourse.getdbt.com/t/usage-of-this-inside-model/7177/1 "2023-03-08T07:17:35Z")

</div>

SELECT  
\*  
FROM {{ this }}

compiled into

select \* from `project`.`dataset`.`result` but the expected outcome is `project`.`dataset`.`table_a`.

similar issue SO thread: [dbt: Using 'this' function has different results in compile/preview vs dbt run - Stack Overflow](https://stackoverflow.com/questions/72635337/dbt-using-this-function-has-different-results-in-compile-preview-vs-dbt-run)

---

<div class="post-metadata">

**Author:** ![a\_slack\_user](https://sea2.discourse-cdn.com/flex020/user_avatar/discourse.getdbt.com/a_slack_user/32/1629_2.png) [@a\_slack\_user](https://discourse.getdbt.com/u/a_slack_user)\
**Post date:** [March 14, 2023, 5:04am UTC](https://discourse.getdbt.com/t/usage-of-this-inside-model/7177/2 "2023-03-14T05:04:30Z")

</div>

dbt-rpc (which powers the dbt Cloud IDE) doesn’t correctly resolve references to `this`. Its replacement, dbt-server, will be able to do this in the future but we don’t have a date to share on when that will be available in the IDE sorry!

Note: `@joellabes (dbt Labs)` originally [posted this reply in Slack](https://getdbt.slack.com/archives/CBSQTAPLG/p1678770263111799?thread_ts=1678259881.071419&cid=CBSQTAPLG). It might not have transferred perfectly.
