Exemplo n.º 1
0
    def compile(self):
        buf = StringIO()
        buf.write(self._create_line())

        props = self._get_table_properties()
        buf.write('\n')
        buf.write(ddl.format_tblproperties(props))

        select_query = self.select.compile()
        buf.write(' AS\n{0}'.format(select_query))
        return buf.getvalue()
Exemplo n.º 2
0
    def compile(self):
        buf = StringIO()
        buf.write(self._create_line())

        schema = ddl.format_schema(self.schema)
        buf.write('\n{0}'.format(schema))

        props = self._get_table_properties()
        buf.write('\n')
        buf.write(ddl.format_tblproperties(props))
        return buf.getvalue()
Exemplo n.º 3
0
    def compile(self):
        buf = StringIO()
        buf.write(self._create_line())

        props = self._get_table_properties()
        buf.write('\n')
        buf.write(ddl.format_tblproperties(props))

        select_query = self.select.compile()
        buf.write(' AS\n{0}'.format(select_query))
        return buf.getvalue()
Exemplo n.º 4
0
    def compile(self):
        buf = StringIO()
        buf.write(self._create_line())

        schema = ddl.format_schema(self.schema)
        buf.write('\n{0}'.format(schema))

        props = self._get_table_properties()
        buf.write('\n')
        buf.write(ddl.format_tblproperties(props))
        return buf.getvalue()
Exemplo n.º 5
0
 def compile(self):
     return '{}\n{} AS\n{}'.format(
         self._create_line(),
         ddl.format_tblproperties(self._get_table_properties()),
         self.select.compile(),
     )
Exemplo n.º 6
0
 def compile(self):
     return '{}\n{}\n{}'.format(
         self._create_line(),
         ddl.format_schema(self.schema),
         ddl.format_tblproperties(self._get_table_properties()),
     )
Exemplo n.º 7
0
 def compile(self):
     return '{}\n{} AS\n{}'.format(
         self._create_line(),
         ddl.format_tblproperties(self._get_table_properties()),
         self.select.compile(),
     )
Exemplo n.º 8
0
 def compile(self):
     return '{}\n{}\n{}'.format(
         self._create_line(),
         ddl.format_schema(self.schema),
         ddl.format_tblproperties(self._get_table_properties()),
     )