Django:SELECT ... FROM ONLY表

Django:SELECT ... FROM ONLY表

问题描述:

Django可以不使用 .raw()进行 SELECT ...仅从... 查询吗?

Can Django do SELECT ... FROM ONLY ... queries without using .raw()?

我需要它来省略对Postgres的查询中的存档表。

I need it to omit archived tables in my queries to Postgres.

我只是在开发版本的django / db中的'ONLY'上做了一个gg grep。
没有命中,所以没有。

I just did a hg grep on 'ONLY' in django/db of the development version. No hits, so no.

大局是什么?为什么不使用.raw()?

What's the bigger picture? Why not use .raw()?