Advanced Dashboards
Overview
DBWillow's dashboard feature lets you create beautiful, interactive dashboards to visualize your database data. Perfect for monitoring metrics, KPIs, and business intelligence.
Dashboard Basics
Creating a Dashboard
- Connect to a database
- Click the "Dashboards" tab
- Click "New Dashboard"
- Give it a name and start adding widgets
Widget Types
DBWillow supports 5 widget types:
- Count Widget: Display a single number (e.g., total users)
- Line Chart: Show trends over time
- Bar Chart: Compare categories
- Pie Chart: Show proportions
- Table Widget: Display detailed data
Creating Widgets
Manual Widget Creation
- Click "Add Widget"
- Select widget type
- Configure the SQL query
- Set display options
- Click "Save"
AI-Powered Widget Generation (Premium)
Describe what you want in plain English:
- "Show me total users as a big number"
- "Display monthly sales as a line chart"
- "Show revenue by category as a bar chart"
The AI generates the widget automatically!
Widget Configuration
SQL Query
Each widget requires a SQL query:
SELECT COUNT(*) as total_users
FROM users
WHERE created_at >= DATE_SUB(NOW(), INTERVAL 30 DAY);
Display Settings
- Title: Widget name
- Refresh Interval: Auto-refresh time (1 min, 5 min, 1 hour, etc.)
- Colors: Customize chart colors
- Axes: Configure chart axes (for charts)
Dashboard Layout
Organizing Widgets
- Drag and drop widgets to rearrange
- Resize widgets by dragging corners
- Create multiple rows and columns
- Save layout automatically
Per-Connection Dashboards
- Each database connection has its own dashboards
- Switch between connections to see different dashboards
- Create multiple dashboards per connection
Widget Types in Detail
Count Widget
Perfect for key metrics:
SELECT COUNT(*) as total
FROM orders
WHERE status = 'completed';
Use cases:
- Total users
- Active orders
- Revenue totals
- Any single metric
Line Chart
Show trends over time:
SELECT
DATE(order_date) as date,
SUM(total) as revenue
FROM orders
WHERE order_date >= DATE_SUB(NOW(), INTERVAL 30 DAY)
GROUP BY DATE(order_date)
ORDER BY date;
Use cases:
- Sales over time
- User growth
- Daily metrics
- Time-series data
Bar Chart
Compare categories:
SELECT
category,
COUNT(*) as product_count
FROM products
GROUP BY category
ORDER BY product_count DESC;
Use cases:
- Revenue by category
- Orders by status
- Users by country
- Any categorical comparison
Pie Chart
Show proportions:
SELECT
status,
COUNT(*) as count
FROM orders
GROUP BY status;
Use cases:
- Order status breakdown
- User distribution
- Product category shares
- Any proportional data
Table Widget
Display detailed data:
SELECT
product_name,
category,
price,
stock_quantity
FROM products
ORDER BY price DESC
LIMIT 10;
Use cases:
- Top products
- Recent orders
- User lists
- Any tabular data
Auto-Refresh
Setting Refresh Intervals
Configure widgets to auto-refresh:
- Real-time: Every 1 minute
- Frequent: Every 5 minutes
- Regular: Every 15 minutes
- Hourly: Every hour
- Manual: Refresh on demand
Use Cases
- Monitoring: Real-time dashboards for operations
- Reporting: Hourly updates for business metrics
- Analysis: Manual refresh for ad-hoc analysis
Exporting Data
Export Options
From any widget:
- Click the export button
- Choose format:
- CSV
- JSON
- Excel
- SQL
- Download the data
Best Practices
Dashboard Organization
- Group related widgets together
- Use clear, descriptive titles
- Keep dashboards focused on specific goals
- Create separate dashboards for different purposes
Performance
- Use efficient SQL queries
- Limit result sets appropriately
- Consider refresh intervals
- Optimize for large datasets
Design
- Use consistent colors
- Keep layouts clean
- Focus on key metrics
- Make it easy to scan
Advanced Features
Custom SQL Queries
Write complex queries for widgets:
- JOINs across multiple tables
- Aggregations and calculations
- Filters and conditions
- Subqueries and CTEs
Widget Templates
Save widget configurations:
- Create a widget
- Configure it perfectly
- Save as template
- Reuse in other dashboards
Troubleshooting
Widget Not Loading
- Check SQL query syntax
- Verify database connection
- Check query execution time
- Review error messages
Slow Refresh
- Optimize SQL queries
- Reduce refresh frequency
- Limit result set size
- Check database performance
Incorrect Data
- Verify SQL query logic
- Check date ranges
- Confirm filters
- Test query in SQL editor first
Next Steps
- Learn about AI Assistant
- Read Creating Dashboards tutorial
- Explore SQL Editor
