sql-blocks 1.25.313022106__py3-none-any.whl → 1.25.414021502__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
sql_blocks/sql_blocks.py CHANGED
@@ -1532,7 +1532,7 @@ class Select(SQLObject):
1532
1532
  Recognizes if the field is from the current table
1533
1533
  '''
1534
1534
  if key in (ORDER_BY, GROUP_BY) and '.' not in field:
1535
- return main.has_named_field(field)
1535
+ return self.has_named_field(field)
1536
1536
  return re.findall(f'\b*{self.alias}[.]', field) != []
1537
1537
 
1538
1538
  @classmethod
@@ -1797,22 +1797,3 @@ def detect(text: str, join_queries: bool = True, format: str='') -> Select | lis
1797
1797
  result += query
1798
1798
  return result
1799
1799
  # ===========================================================================================//
1800
-
1801
- if __name__ == "__main__":
1802
- print('='*50)
1803
- movimento = Select(
1804
- 'Movimento.parquet M',
1805
- direcao=Case('entrada_saida').when(
1806
- eq('E'), 1
1807
- ).else_value( -1 ),
1808
- pessoa=Field
1809
- )
1810
- print(movimento)
1811
- print('-'*50)
1812
- cte = CTE('Ciclo C', [movimento])
1813
- cte(
1814
- pessoa=[GroupBy, Field],
1815
- direcao=Having.sum(gt(0))
1816
- )
1817
- print(cte)
1818
- print('='*50)
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: sql_blocks
3
- Version: 1.25.313022106
3
+ Version: 1.25.414021502
4
4
  Summary: Allows you to create objects for parts of SQL query commands. Also to combine these objects by joining them, adding or removing parts...
5
5
  Home-page: https://github.com/julio-cascalles/sql_blocks
6
6
  Author: Júlio Cascalles
@@ -0,0 +1,7 @@
1
+ sql_blocks/__init__.py,sha256=5ItzGCyqqa6kwY8wvF9kapyHsAiWJ7KEXCcC-OtdXKg,37
2
+ sql_blocks/sql_blocks.py,sha256=HUDdXrSDuippY7buAAMuFyYS9mRetAu7woy_6yBUQ7c,60161
3
+ sql_blocks-1.25.414021502.dist-info/LICENSE,sha256=6kbiFSfobTZ7beWiKnHpN902HgBx-Jzgcme0SvKqhKY,1091
4
+ sql_blocks-1.25.414021502.dist-info/METADATA,sha256=3GGtGw0pl-9zIqwCZM2AH0GHykI1Sawkb0fpfpsLMlc,20512
5
+ sql_blocks-1.25.414021502.dist-info/WHEEL,sha256=GJ7t_kWBFywbagK5eo9IoUwLW6oyOeTKmQ-9iHFVNxQ,92
6
+ sql_blocks-1.25.414021502.dist-info/top_level.txt,sha256=57AbUvUjYNy4m1EqDaU3WHeP-uyIAfV0n8GAUp1a1YQ,11
7
+ sql_blocks-1.25.414021502.dist-info/RECORD,,
@@ -1,7 +0,0 @@
1
- sql_blocks/__init__.py,sha256=5ItzGCyqqa6kwY8wvF9kapyHsAiWJ7KEXCcC-OtdXKg,37
2
- sql_blocks/sql_blocks.py,sha256=rJThLDIWJpyI-plCdfpG5UwZDpp_pEriUbw1GgXRs0U,60595
3
- sql_blocks-1.25.313022106.dist-info/LICENSE,sha256=6kbiFSfobTZ7beWiKnHpN902HgBx-Jzgcme0SvKqhKY,1091
4
- sql_blocks-1.25.313022106.dist-info/METADATA,sha256=M9_xMMjLg9SYWM4m2ocomFow70Xu8eoqlBZ2BQdt3_4,20512
5
- sql_blocks-1.25.313022106.dist-info/WHEEL,sha256=GJ7t_kWBFywbagK5eo9IoUwLW6oyOeTKmQ-9iHFVNxQ,92
6
- sql_blocks-1.25.313022106.dist-info/top_level.txt,sha256=57AbUvUjYNy4m1EqDaU3WHeP-uyIAfV0n8GAUp1a1YQ,11
7
- sql_blocks-1.25.313022106.dist-info/RECORD,,