sqlshell 0.2.1__py3-none-any.whl → 0.2.3__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.

Potentially problematic release.


This version of sqlshell might be problematic. Click here for more details.

@@ -0,0 +1,281 @@
1
+ Metadata-Version: 2.4
2
+ Name: sqlshell
3
+ Version: 0.2.3
4
+ Summary: A powerful SQL shell with GUI interface for data analysis
5
+ Author: SQLShell Team
6
+ License-Expression: MIT
7
+ Project-URL: Homepage, https://github.com/oyvinrog/SQLShell
8
+ Keywords: sql,data analysis,gui,duckdb
9
+ Classifier: Development Status :: 3 - Alpha
10
+ Classifier: Intended Audience :: Developers
11
+ Classifier: Programming Language :: Python :: 3
12
+ Classifier: Programming Language :: Python :: 3.8
13
+ Classifier: Programming Language :: Python :: 3.9
14
+ Classifier: Programming Language :: Python :: 3.10
15
+ Classifier: Programming Language :: Python :: 3.11
16
+ Requires-Python: >=3.8
17
+ Description-Content-Type: text/markdown
18
+ Requires-Dist: pandas>=2.0.0
19
+ Requires-Dist: numpy>=1.24.0
20
+ Requires-Dist: PyQt6>=6.4.0
21
+ Requires-Dist: duckdb>=0.9.0
22
+ Requires-Dist: openpyxl>=3.1.0
23
+ Requires-Dist: pyarrow>=14.0.1
24
+ Requires-Dist: fastparquet>=2023.10.1
25
+ Requires-Dist: xlrd>=2.0.1
26
+ Requires-Dist: deltalake
27
+ Requires-Dist: Pillow>=10.0.0
28
+ Requires-Dist: shap
29
+ Requires-Dist: xgboost
30
+ Requires-Dist: scikit-learn
31
+ Requires-Dist: matplotlib>=3.10.0
32
+ Requires-Dist: scipy>=1.15.0
33
+
34
+ # SQLShell
35
+
36
+ <div align="center">
37
+
38
+ <img src="https://github.com/oyvinrog/SQLShell/raw/main/sqlshell_logo.png" alt="SQLShell Logo" width="180" height="auto">
39
+
40
+ **A powerful SQL shell with GUI interface for data analysis**
41
+
42
+ <img src="https://github.com/oyvinrog/SQLShell/raw/main/sqlshell_demo.png" alt="SQLShell Interface" width="80%" height="auto">
43
+
44
+ </div>
45
+
46
+ ## 🚀 Key Features
47
+
48
+ - **Interactive SQL Interface** - Rich syntax highlighting for enhanced query writing
49
+ - **Context-Aware Suggestions** - Intelligent SQL autocompletion based on query context and schema
50
+ - **DuckDB Integration** - Powerful analytical queries powered by DuckDB
51
+ - **Multi-Format Support** - Import and query Excel (.xlsx, .xls), CSV, and Parquet files effortlessly
52
+ - **Modern UI** - Clean, tabular results display with intuitive controls
53
+ - **Table Preview** - Quick view of imported data tables
54
+ - **Test Data Generation** - Built-in sample data for testing and learning
55
+ - **Multiple Views** - Support for multiple concurrent table views
56
+ - **Productivity Tools** - Streamlined workflow with keyboard shortcuts (e.g., Ctrl+Enter for query execution)
57
+ - **Explain Column** - Analyze relationships between data columns directly from query results
58
+
59
+ ## 📦 Installation
60
+
61
+ ### Using pip (Recommended)
62
+
63
+ ```bash
64
+ pip install sqlshell
65
+ ```
66
+
67
+ ### Linux Setup with Virtual Environment
68
+
69
+ ```bash
70
+ # Create and activate virtual environment
71
+ python3 -m venv ~/.venv/sqlshell
72
+ source ~/.venv/sqlshell/bin/activate
73
+
74
+ # Install SQLShell
75
+ pip install sqlshell
76
+
77
+ # Configure shell alias
78
+ echo 'alias sqls="~/.venv/sqlshell/bin/sqls"' >> ~/.bashrc # or ~/.zshrc for Zsh
79
+ source ~/.bashrc # or source ~/.zshrc
80
+ ```
81
+
82
+ ### Development Installation
83
+
84
+ ```bash
85
+ git clone https://github.com/oyvinrog/SQLShell.git
86
+ cd SQLShell
87
+ pip install -e .
88
+ ```
89
+
90
+ ## 🎯 Getting Started
91
+
92
+ 1. **Launch the Application**
93
+ ```bash
94
+ sqls
95
+ ```
96
+
97
+ If the `sqls` command doesn't work (e.g., "access denied" on Windows), you can use this alternative:
98
+ ```bash
99
+ python -c "import sqlshell; sqlshell.start()"
100
+ ```
101
+
102
+ 2. **Database Connection**
103
+ - SQLShell automatically connects to a local DuckDB database named 'pool.db'
104
+
105
+ 3. **Working with Data Files**
106
+ - Click "Load Files" to select your Excel, CSV, or Parquet files
107
+ - File contents are loaded as queryable SQL tables
108
+ - Query using standard SQL syntax
109
+
110
+ 4. **Query Execution**
111
+ - Enter SQL in the editor
112
+ - Execute using Ctrl+Enter or the "Execute" button
113
+ - View results in the structured output panel
114
+
115
+ 5. **Test Data**
116
+ - Load sample test data using the "Test" button for quick experimentation
117
+
118
+ 6. **Using Context-Aware Suggestions**
119
+ - Press Ctrl+Space to manually trigger suggestions
120
+ - Suggestions appear automatically as you type
121
+ - Context-specific suggestions based on your query position:
122
+ - After SELECT: columns and functions
123
+ - After FROM/JOIN: tables with join conditions
124
+ - After WHERE: columns with appropriate operators
125
+ - Inside functions: relevant column suggestions
126
+
127
+ 7. **Column Analysis**
128
+ - Right-click on column headers in the results pane
129
+ - Access features like sorting, filtering, and the "Explain Column" analysis tool
130
+
131
+ ## 📝 Query Examples
132
+
133
+ ### Basic Join Operation
134
+ ```sql
135
+ SELECT *
136
+ FROM sample_sales_data cd
137
+ INNER JOIN product_catalog pc ON pc.productid = cd.productid
138
+ LIMIT 3;
139
+ ```
140
+
141
+ ### Multi-Statement Queries
142
+ ```sql
143
+ -- Create a temporary view
144
+ CREATE OR REPLACE TEMPORARY VIEW test_v AS
145
+ SELECT *
146
+ FROM sample_sales_data cd
147
+ INNER JOIN product_catalog pc ON pc.productid = cd.productid;
148
+
149
+ -- Query the view
150
+ SELECT DISTINCT productid
151
+ FROM test_v;
152
+ ```
153
+
154
+ ## 💡 Pro Tips
155
+
156
+ - Use temporary views for complex query organization
157
+ - Leverage keyboard shortcuts for efficient workflow
158
+ - Explore the multi-format support for various data sources
159
+ - Create multiple tabs for parallel query development
160
+ - The context-aware suggestions learn from your query patterns
161
+ - Type `table_name.` to see all columns for a specific table
162
+ - After JOIN keyword, the system suggests relevant tables and join conditions
163
+
164
+ ## 📊 Table Profiling
165
+
166
+ SQLShell provides powerful table profiling tools to help you understand your data. These tools are accessible from the left-hand side table menu via right-click on any table:
167
+
168
+ <div align="center">
169
+ <img src="https://github.com/oyvinrog/SQLShell/raw/main/column_profiler.png" alt="Column Profiler" width="80%" height="auto">
170
+ </div>
171
+
172
+ ### Table Profiling Options
173
+
174
+ Right-click on any table in the left panel to access these profiling tools:
175
+
176
+ 1. **Analyze Column Importance**
177
+ - Calculates entropy for each column to identify the most information-rich fields
178
+ - Visualizes column importance with color-coded bars
179
+ - Helps identify which columns are most useful for analysis and modeling
180
+
181
+ 2. **Profile Table Structure**
182
+ - Identifies candidate keys and functional dependencies
183
+ - Discovers potential primary keys and relationships between columns
184
+ - Suggests possible normalized table structures
185
+ - Helps understand table organization and optimize schema design
186
+
187
+ 3. **Analyze Column Distributions**
188
+ - Generates histograms, box plots, and other statistical visualizations
189
+ - Identifies the distribution pattern of each column (normal, uniform, etc.)
190
+ - Provides detailed statistics like min, max, mean, median, skewness
191
+ - Helps identify outliers and understand data patterns
192
+
193
+ 4. **Analyze Foreign Keys** (multi-table selection)
194
+ - Select multiple tables by holding Ctrl or Shift while clicking
195
+ - Right-click to access "Analyze Foreign Keys Between X Tables"
196
+ - Automatically discovers potential foreign key relationships between tables
197
+ - Identifies matching columns that could serve as join conditions
198
+ - Helps understand cross-table relationships in your data model
199
+
200
+ ### Using the Profilers
201
+
202
+ 1. **Access the Profilers**
203
+ - Right-click on any table in the schema browser
204
+ - Select the desired profiling option from the context menu
205
+ - For foreign key analysis, select multiple tables first
206
+
207
+ 2. **Interpret the Results**
208
+ - Each profiler provides interactive visualizations
209
+ - Hover over charts for detailed information
210
+ - Switch between different views using the tabs
211
+ - Sort and filter results to focus on specific columns
212
+
213
+ 3. **Benefits**
214
+ - Quickly understand data composition without writing queries
215
+ - Identify data quality issues and outliers
216
+ - Discover relationships between columns
217
+ - Make informed decisions about query optimization
218
+
219
+ The table profiling tools are invaluable for exploratory data analysis, helping you gain insights before writing complex queries.
220
+
221
+ ## 📊 Column Analysis
222
+
223
+ SQLShell provides powerful tools to analyze individual columns directly from your query results:
224
+
225
+ ### Explain Column Feature
226
+
227
+ The "Explain Column" feature helps you understand the relationships between columns in your query results:
228
+
229
+ 1. **How to Access**:
230
+ - Right-click on any column header in the query results table
231
+ - Select "Explain Column" from the context menu
232
+
233
+ 2. **What It Does**:
234
+ - Analyzes the selected column's relationship with other columns in the result set
235
+ - Identifies correlations and dependencies between columns
236
+ - Provides visualizations to help understand the column's importance and distribution
237
+
238
+ 3. **Benefits**:
239
+ - Quickly identify which columns are most related to your target column
240
+ - Discover hidden patterns and relationships in your data
241
+ - Make data-driven decisions without writing complex analytical queries
242
+
243
+ ### Multivariate Analysis Feature
244
+
245
+ The Column Profiler now offers in-depth multivariate analysis to explore relationships between columns:
246
+
247
+ 1. **How to Access**:
248
+ - In the Column Profiler, double-click on any feature in the importance table
249
+ - A detailed visualization window will appear showing the relationship between the selected feature and the target column
250
+
251
+ 2. **Smart Visualizations**:
252
+ - Automatically selects the most appropriate visualization based on data types:
253
+ - **Numeric vs. Numeric**: Scatter plot with regression line
254
+ - **Categorical vs. Numeric**: Bar chart showing average values
255
+ - **Numeric vs. Categorical**: Box plot showing distribution
256
+ - **Categorical vs. Categorical**: Heatmap showing relationship strength
257
+
258
+ 3. **Benefits**:
259
+ - Gain deeper insights into how features relate to your target variable
260
+ - Understand which features have strong predictive relationships
261
+ - Identify patterns and outliers in multivariate relationships
262
+ - Make better decisions about feature selection for analysis and modeling
263
+
264
+ This feature is particularly useful for exploratory data analysis, helping you understand your data structure and relationships on the fly.
265
+
266
+ ## 📋 Requirements
267
+
268
+ - Python 3.8 or higher
269
+ - Dependencies (automatically installed):
270
+ - PyQt6 ≥ 6.4.0
271
+ - DuckDB ≥ 0.9.0
272
+ - Pandas ≥ 2.0.0
273
+ - NumPy ≥ 1.24.0
274
+ - openpyxl ≥ 3.1.0 (Excel support)
275
+ - pyarrow ≥ 14.0.1 (Parquet support)
276
+ - fastparquet ≥ 2023.10.1 (Alternative parquet engine)
277
+ - xlrd ≥ 2.0.1 (Support for older .xls files)
278
+
279
+ ## 📄 License
280
+
281
+ This project is licensed under the MIT License - see the LICENSE file for details.
@@ -1,11 +1,11 @@
1
1
  sqlshell/LICENSE,sha256=YFVzvqHDVzBVtEZoKwcHhashVdNy4P7tDEQ561jAdyo,1070
2
2
  sqlshell/MANIFEST.in,sha256=UautKSW4Kzjsy1Ti05-P58qRgM4ct4mmG3aserBGaX0,144
3
- sqlshell/README.md,sha256=UoWQzdsYThrOoajT40iOtpI73g5ANB7w12vll0eH0Ck,1357
4
- sqlshell/__init__.py,sha256=hj4Dacq3O6bIAYlJHJxnY2fVb1g_4l8s9yzvpSbe6oU,205
3
+ sqlshell/README.md,sha256=_FPMDx0xcXt00Qpodw3JwwNeptE2qT0LUBCdNhEtRsA,1739
4
+ sqlshell/__init__.py,sha256=_uIktHV8tsYR8GPHq3D161noGqbU1rSPmyFBZXr17eY,263
5
5
  sqlshell/context_suggester.py,sha256=OdfSBqwKWtf6yGj-_cNjf9RZG9cc70TWZ_7ieAVKJqk,33970
6
- sqlshell/create_test_data.py,sha256=uJSFyqm8zYWpyERPd29iMu-EbtvKiwK5WV0N-LibNOc,5385
6
+ sqlshell/create_test_data.py,sha256=3LzUEbAn7cNgahuivXB7XTnb3osE-n-VPJeoaFBP8tE,6595
7
7
  sqlshell/editor.py,sha256=iWSYUtsNCud7HWZrcqD9Ef7FEa0nt7ekeUHV6CmCgao,39635
8
- sqlshell/main.py,sha256=vt7s6dXmY6iw-Y3jr2YtPNMwwvdqPu1zqNRNidtIRN0,150575
8
+ sqlshell/main.py,sha256=MLF-vEONG3rxNUoxxWfLJClwFUoTBS0-_BYQ0Ie20o4,162160
9
9
  sqlshell/menus.py,sha256=hiT1CXXnsRKkai7oJlPi94du_GKtIhl5X5LOGvqcOqs,5684
10
10
  sqlshell/query_tab.py,sha256=9Yu_7MRikZXrQ003N2HOvjFEBdiz_J9ZLWgTzXPiumc,8404
11
11
  sqlshell/splash_screen.py,sha256=K0Ku_nXJWmWSnVEh2OttIthRZcnUoY_tmjIAWIWLm7Y,17604
@@ -13,7 +13,7 @@ sqlshell/sqlshell_demo.png,sha256=dPp9J1FVqQVfrh-gekosuha2Jw2p2--wxbOmt2kr7fg,13
13
13
  sqlshell/styles.py,sha256=EGA_Ow-XerPEQgj82ts3fnqkEPMcjSlJPblbPu9L__s,7135
14
14
  sqlshell/suggester_integration.py,sha256=w3fKuSq5ex5OHxSBzZunyq3mbGvX06-7nxgLClnK5Kw,13232
15
15
  sqlshell/syntax_highlighter.py,sha256=mPwsD8N4XzAUx0IgwlelyfjUhe0xmH0Ug3UI9hTcHz0,5861
16
- sqlshell/table_list.py,sha256=ET9UGxhRL2j42GC6WqocotvQIOUzRskH9BnmciVX_As,37670
16
+ sqlshell/table_list.py,sha256=0V2vQXjah8uWdRaRcB0w9WzclaFX5HulCUmmJEjUW8k,41585
17
17
  sqlshell/data/create_test_data.py,sha256=sUTcf50V8-bVwYV2VNTLK65c-iHiU4wb99By67I10zM,5404
18
18
  sqlshell/db/__init__.py,sha256=AJGRkywFCnJliwfOBvtE_ISXjdESkRea7lBFM5KjuTU,152
19
19
  sqlshell/db/database_manager.py,sha256=DRPoRYgY9DthD1YvLuMeo-aRfaAAcdAKZKXMPDmAcsg,35722
@@ -30,12 +30,15 @@ sqlshell/sqlshell/create_test_data.py,sha256=TFXgWeK1l3l_c4Dg38yS8Df4sBUfOZcBucX
30
30
  sqlshell/sqlshell/create_test_databases.py,sha256=oqryFJJahqLFsAjBFM4r9Fe1ea7djDcRpT9U_aBf7PU,3573
31
31
  sqlshell/ui/__init__.py,sha256=2CsTDAvRZJ99gkjs3-rdwkxyGVAKXX6ueOhPdP1VXQc,206
32
32
  sqlshell/ui/bar_chart_delegate.py,sha256=tbtIt2ZqPIcYWNJzpONpYa0CYURkLdjkg23TI7TmOKY,1881
33
- sqlshell/ui/filter_header.py,sha256=c4Mg1J1yTUfrnT9C-xDWHhcauRsgU3WNfvVInv1J814,16074
33
+ sqlshell/ui/filter_header.py,sha256=FjIGyXExjg5OqNH_0QN0VXN3E6IrVkwHQVW3mRrj2xg,16903
34
34
  sqlshell/utils/__init__.py,sha256=iPKvOsKcfnV7xvhQVOz8BiQ4kbFZ7PGUW8vg0vyMqvk,225
35
+ sqlshell/utils/profile_column.py,sha256=O7CMPwoEemk3xpzQ_5bqOofCy13TvDEkXDsnTcy0UXs,45811
36
+ sqlshell/utils/profile_distributions.py,sha256=1AcgubrouKYCiVoXtYz6RVX8kXSp6VaoEoJInXMU0RU,25379
35
37
  sqlshell/utils/profile_entropy.py,sha256=pJTcXlBkSEPzL3Fvxizf5gBkw6IsUjfa9Y6MjAqF1do,13238
38
+ sqlshell/utils/profile_foreign_keys.py,sha256=bK5IpFoIeJZVI99s4tOj6fLhOef8q2SMnIW2W91fHzc,17752
36
39
  sqlshell/utils/profile_keys.py,sha256=ajdBTqvZVmAlVaY-kDmv_D8D3sKASG75PLTzf8Y8nX4,14170
37
- sqlshell-0.2.1.dist-info/METADATA,sha256=5YYpUc-C9LMVcPdVe8WVGPkjyQE4WyEUvasNvVSAQW8,6101
38
- sqlshell-0.2.1.dist-info/WHEEL,sha256=ck4Vq1_RXyvS4Jt6SI0Vz6fyVs4GWg7AINwpsaGEgPE,91
39
- sqlshell-0.2.1.dist-info/entry_points.txt,sha256=Kd0fOvyOW7UiTgTVY7abVOmDIH2Y2nawGTp5kVadac4,44
40
- sqlshell-0.2.1.dist-info/top_level.txt,sha256=ahwsMFhvAqI97ZkT2xvHL5iZCO1p13mNiUOFkdSFwms,9
41
- sqlshell-0.2.1.dist-info/RECORD,,
40
+ sqlshell-0.2.3.dist-info/METADATA,sha256=MJVVxTIUp8tn_Lb6UYhICOg-3oY70F1TmS1Aj8-TSl8,10235
41
+ sqlshell-0.2.3.dist-info/WHEEL,sha256=Nw36Djuh_5VDukK0H78QzOX-_FQEo6V37m3nkm96gtU,91
42
+ sqlshell-0.2.3.dist-info/entry_points.txt,sha256=Kd0fOvyOW7UiTgTVY7abVOmDIH2Y2nawGTp5kVadac4,44
43
+ sqlshell-0.2.3.dist-info/top_level.txt,sha256=ahwsMFhvAqI97ZkT2xvHL5iZCO1p13mNiUOFkdSFwms,9
44
+ sqlshell-0.2.3.dist-info/RECORD,,
@@ -1,5 +1,5 @@
1
1
  Wheel-Version: 1.0
2
- Generator: setuptools (80.0.0)
2
+ Generator: setuptools (80.7.1)
3
3
  Root-Is-Purelib: true
4
4
  Tag: py3-none-any
5
5
 
@@ -1,198 +0,0 @@
1
- Metadata-Version: 2.4
2
- Name: sqlshell
3
- Version: 0.2.1
4
- Summary: A powerful SQL shell with GUI interface for data analysis
5
- Author: SQLShell Team
6
- License-Expression: MIT
7
- Project-URL: Homepage, https://github.com/oyvinrog/SQLShell
8
- Keywords: sql,data analysis,gui,duckdb
9
- Classifier: Development Status :: 3 - Alpha
10
- Classifier: Intended Audience :: Developers
11
- Classifier: Programming Language :: Python :: 3
12
- Classifier: Programming Language :: Python :: 3.8
13
- Classifier: Programming Language :: Python :: 3.9
14
- Classifier: Programming Language :: Python :: 3.10
15
- Classifier: Programming Language :: Python :: 3.11
16
- Requires-Python: >=3.8
17
- Description-Content-Type: text/markdown
18
- Requires-Dist: pandas>=2.0.0
19
- Requires-Dist: numpy>=1.24.0
20
- Requires-Dist: PyQt6>=6.4.0
21
- Requires-Dist: duckdb>=0.9.0
22
- Requires-Dist: openpyxl>=3.1.0
23
- Requires-Dist: pyarrow>=14.0.1
24
- Requires-Dist: fastparquet>=2023.10.1
25
- Requires-Dist: xlrd>=2.0.1
26
- Requires-Dist: deltalake
27
- Requires-Dist: Pillow>=10.0.0
28
-
29
- # SQLShell
30
-
31
- <div align="center">
32
-
33
- <img src="sqlshell_logo.png" alt="SQLShell Logo" width="180" height="auto">
34
-
35
- **A powerful SQL shell with GUI interface for data analysis**
36
-
37
- <img src="sqlshell_demo.png" alt="SQLShell Interface" width="80%" height="auto">
38
-
39
- </div>
40
-
41
- ## 🚀 Key Features
42
-
43
- - **Interactive SQL Interface** - Rich syntax highlighting for enhanced query writing
44
- - **Context-Aware Suggestions** - Intelligent SQL autocompletion based on query context and schema
45
- - **DuckDB Integration** - Powerful analytical queries powered by DuckDB
46
- - **Multi-Format Support** - Import and query Excel (.xlsx, .xls), CSV, and Parquet files effortlessly
47
- - **Modern UI** - Clean, tabular results display with intuitive controls
48
- - **Table Preview** - Quick view of imported data tables
49
- - **Test Data Generation** - Built-in sample data for testing and learning
50
- - **Multiple Views** - Support for multiple concurrent table views
51
- - **Productivity Tools** - Streamlined workflow with keyboard shortcuts (e.g., Ctrl+Enter for query execution)
52
-
53
- ## 📦 Installation
54
-
55
- ### Using pip (Recommended)
56
-
57
- ```bash
58
- pip install sqlshell
59
- ```
60
-
61
- ### Linux Setup with Virtual Environment
62
-
63
- ```bash
64
- # Create and activate virtual environment
65
- python3 -m venv ~/.venv/sqlshell
66
- source ~/.venv/sqlshell/bin/activate
67
-
68
- # Install SQLShell
69
- pip install sqlshell
70
-
71
- # Configure shell alias
72
- echo 'alias sqls="~/.venv/sqlshell/bin/sqls"' >> ~/.bashrc # or ~/.zshrc for Zsh
73
- source ~/.bashrc # or source ~/.zshrc
74
- ```
75
-
76
- ### Development Installation
77
-
78
- ```bash
79
- git clone https://github.com/oyvinrog/SQLShell.git
80
- cd SQLShell
81
- pip install -e .
82
- ```
83
-
84
- ## 🎯 Getting Started
85
-
86
- 1. **Launch the Application**
87
- ```bash
88
- sqls
89
- ```
90
-
91
- If the `sqls` command doesn't work (e.g., "access denied" on Windows), you can use this alternative:
92
- ```bash
93
- python -c "import sqlshell; sqlshell.start()"
94
- ```
95
-
96
- 2. **Database Connection**
97
- - SQLShell automatically connects to a local DuckDB database named 'pool.db'
98
-
99
- 3. **Working with Data Files**
100
- - Click "Load Files" to select your Excel, CSV, or Parquet files
101
- - File contents are loaded as queryable SQL tables
102
- - Query using standard SQL syntax
103
-
104
- 4. **Query Execution**
105
- - Enter SQL in the editor
106
- - Execute using Ctrl+Enter or the "Execute" button
107
- - View results in the structured output panel
108
-
109
- 5. **Test Data**
110
- - Load sample test data using the "Test" button for quick experimentation
111
-
112
- 6. **Using Context-Aware Suggestions**
113
- - Press Ctrl+Space to manually trigger suggestions
114
- - Suggestions appear automatically as you type
115
- - Context-specific suggestions based on your query position:
116
- - After SELECT: columns and functions
117
- - After FROM/JOIN: tables with join conditions
118
- - After WHERE: columns with appropriate operators
119
- - Inside functions: relevant column suggestions
120
-
121
- ## 📝 Query Examples
122
-
123
- ### Basic Join Operation
124
- ```sql
125
- SELECT *
126
- FROM sample_sales_data cd
127
- INNER JOIN product_catalog pc ON pc.productid = cd.productid
128
- LIMIT 3;
129
- ```
130
-
131
- ### Multi-Statement Queries
132
- ```sql
133
- -- Create a temporary view
134
- CREATE OR REPLACE TEMPORARY VIEW test_v AS
135
- SELECT *
136
- FROM sample_sales_data cd
137
- INNER JOIN product_catalog pc ON pc.productid = cd.productid;
138
-
139
- -- Query the view
140
- SELECT DISTINCT productid
141
- FROM test_v;
142
- ```
143
-
144
- ## 💡 Pro Tips
145
-
146
- - Use temporary views for complex query organization
147
- - Leverage keyboard shortcuts for efficient workflow
148
- - Explore the multi-format support for various data sources
149
- - Create multiple tabs for parallel query development
150
- - The context-aware suggestions learn from your query patterns
151
- - Type `table_name.` to see all columns for a specific table
152
- - After JOIN keyword, the system suggests relevant tables and join conditions
153
-
154
- ## 📊 Column Profiler
155
-
156
- The Column Profiler provides quick statistical insights into your table columns:
157
-
158
- <img src="column_profiler.png" alt="Column Profiler" width="80%" height="auto">
159
-
160
- ### Using the Column Profiler
161
-
162
- 1. **Access the Profiler**
163
- - Right-click on any table in the schema browser
164
- - Select "Profile Table" from the context menu
165
-
166
- 2. **View Column Statistics**
167
- - Instantly see key metrics for each column:
168
- - Data type
169
- - Non-null count and percentage
170
- - Unique values count
171
- - Mean, median, min, and max values (for numeric columns)
172
- - Most frequent values and their counts
173
- - Distribution visualization
174
-
175
- 3. **Benefits**
176
- - Quickly understand data distribution
177
- - Identify outliers and data quality issues
178
- - Make informed decisions about query conditions
179
- - Assess column cardinality for join operations
180
-
181
- The Column Profiler is an invaluable tool for exploratory data analysis, helping you gain insights before writing complex queries.
182
-
183
- ## 📋 Requirements
184
-
185
- - Python 3.8 or higher
186
- - Dependencies (automatically installed):
187
- - PyQt6 ≥ 6.4.0
188
- - DuckDB ≥ 0.9.0
189
- - Pandas ≥ 2.0.0
190
- - NumPy ≥ 1.24.0
191
- - openpyxl ≥ 3.1.0 (Excel support)
192
- - pyarrow ≥ 14.0.1 (Parquet support)
193
- - fastparquet ≥ 2023.10.1 (Alternative parquet engine)
194
- - xlrd ≥ 2.0.1 (Support for older .xls files)
195
-
196
- ## 📄 License
197
-
198
- This project is licensed under the MIT License - see the LICENSE file for details.