Return a callable object that will produce copies of this :class:`_engine.Result` when invoked. The callable object returned is an instance of :class:`_engine.FrozenResult`. This is used for result set caching. The method must be called on the result when i
(self)
| 1146 | ) |
| 1147 | |
| 1148 | def freeze(self) -> FrozenResult[Unpack[_Ts]]: |
| 1149 | """Return a callable object that will produce copies of this |
| 1150 | :class:`_engine.Result` when invoked. |
| 1151 | |
| 1152 | The callable object returned is an instance of |
| 1153 | :class:`_engine.FrozenResult`. |
| 1154 | |
| 1155 | This is used for result set caching. The method must be called |
| 1156 | on the result when it has been unconsumed, and calling the method |
| 1157 | will consume the result fully. When the :class:`_engine.FrozenResult` |
| 1158 | is retrieved from a cache, it can be called any number of times where |
| 1159 | it will produce a new :class:`_engine.Result` object each time |
| 1160 | against its stored set of rows. |
| 1161 | |
| 1162 | .. seealso:: |
| 1163 | |
| 1164 | :ref:`do_orm_execute_re_executing` - example usage within the |
| 1165 | ORM to implement a result-set cache. |
| 1166 | |
| 1167 | """ |
| 1168 | |
| 1169 | return FrozenResult(self) |
| 1170 | |
| 1171 | def merge( |
| 1172 | self, *others: Result[Unpack[TupleAny]] |