Changes between Initial Version and Version 1 of Ticket #24154, comment 1
- Timestamp:
- Jan 15, 2015, 7:19:57 AM (10 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
Ticket #24154, comment 1
initial v1 1 My current feeling is that we could perhaps do this in as_sql() for those backends that need it. So, StdDev.as_sql() would read something like:1 My current feeling is that we could perhaps do this in as_sql() for those expressions that need it. So, StdDev.as_sql() would read something like: 2 2 {{{ 3 3 def as_sql(self, compiler, connection): … … 7 7 8 8 While it is a bit ugly to check the support in as_sql(), this would allow us to avoid any overhead for those expressions that do not need the check. There is a justification for this, too. The as_sql() method should throw an error if there is no way to generate SQL for the given connection. 9 10 EDIT: I originally wrote "do this in as_sql() for those backends..." instead of "for those expressions..."