MCPcopy Create free account
hub / github.com/sqlalchemy/sqlalchemy / construct_expanded_state

Method construct_expanded_state

lib/sqlalchemy/sql/compiler.py:1837–1858  ·  view source on GitHub ↗

Return a new :class:`.ExpandedState` for a given parameter set. For queries that use "expanding" or other late-rendered parameters, this method will provide for both the finalized SQL string as well as the parameters that would be used for a particular parameter set.

(
        self,
        params: Optional[_CoreSingleExecuteParams] = None,
        escape_names: bool = True,
    )

Source from the content-addressed store, hash-verified

1835 return self
1836
1837 def construct_expanded_state(
1838 self,
1839 params: Optional[_CoreSingleExecuteParams] = None,
1840 escape_names: bool = True,
1841 ) -> ExpandedState:
1842 """Return a new :class:`.ExpandedState` for a given parameter set.
1843
1844 For queries that use "expanding" or other late-rendered parameters,
1845 this method will provide for both the finalized SQL string as well
1846 as the parameters that would be used for a particular parameter set.
1847
1848 .. versionadded:: 2.0.0rc1
1849
1850 """
1851 parameters = self.construct_params(
1852 params,
1853 escape_names=escape_names,
1854 _no_postcompile=True,
1855 )
1856 return self._process_parameters_for_postcompile(
1857 parameters,
1858 )
1859
1860 def construct_params(
1861 self,

Calls 2

construct_paramsMethod · 0.95