GitHub user dosubot[bot] added a comment to the discussion: Create Dataset
<!-- Answer --> For your first question, creating one dataset to handle all charts in a dashboard versus one dataset per chart depends on your specific use case and performance considerations. Using a single dataset for multiple charts can simplify management and ensure consistency across charts. However, it might lead to performance issues if the dataset is large and complex. On the other hand, using separate datasets for each chart can optimize performance by tailoring each dataset to the specific needs of the chart, but it may require more maintenance. Regarding your second question about joining multiple tables, there are some considerations to keep in mind: 1. **Explore or Visualization UI Limitation**: You cannot join multiple tables directly in the Explore or Visualization UI. A Superset SQLAlchemy datasource can only be a single table or a view. 2. **Use of Views**: To join multiple tables, you can create a view that abstracts an arbitrary SQL query as a virtual table. This allows you to join and union multiple tables and apply transformations using SQL expressions. However, the performance is dependent on your database, as Superset will run a query on top of your view. 3. **Performance Considerations**: It is recommended to limit joining your main large table to one or many small tables only. Avoid using `GROUP BY` in your view, as Superset will perform its own `GROUP BY`, which might slow down performance. 4. **SQL Lab**: In SQL Lab, there is no limitation on joining multiple tables. You can write SQL queries to join multiple tables as long as your database account has access to them. 5. **Querying Across Databases**: Superset offers an experimental feature for querying across different databases using the "Superset meta database." This allows you to query any table in any of the configured databases. However, this feature is experimental and comes with security considerations, such as ensuring proper permissions are enforced to prevent unauthorized data access <sup>[[1]](https://github.com/apache/superset/blob/master/docs/docs/faq.mdx)</sup><sup>[[2]](https://github.com/apache/superset/blob/master/docs/docs/configuration/databases.mdx)</sup>. <!-- Dosu Comment Footer --> *To continue talking to [Dosu](https://dosu.dev), mention @dosu.* --- <sup>Help Dosu learn! Give it feedback: [Great Response](https://app.dosu.dev/response-feedback/1bd9ed06-07cc-4e71-b597-d9a9a135f7de?feedback_type=great_response) | [Irrelevant Answer](https://app.dosu.dev/response-feedback/1bd9ed06-07cc-4e71-b597-d9a9a135f7de?feedback_type=irrelevant_answer) | [Incorrect Sources](https://app.dosu.dev/response-feedback/1bd9ed06-07cc-4e71-b597-d9a9a135f7de?feedback_type=incorrect_sources) | [Too Verbose](https://app.dosu.dev/response-feedback/1bd9ed06-07cc-4e71-b597-d9a9a135f7de?feedback_type=too_verbose) | [Hallucination](https://app.dosu.dev/response-feedback/1bd9ed06-07cc-4e71-b597-d9a9a135f7de?feedback_type=hallucination) | [Bug Report](https://app.dosu.dev/response-feedback/1bd9ed06-07cc-4e71-b597-d9a9a135f7de?feedback_type=bug_report) | [Other](https://app.dosu.dev/response-feedback/1bd9ed06-07cc-4e71-b597-d9a9a135f7de?feedback_type=other)</sup> GitHub link: https://github.com/apache/superset/discussions/33082#discussioncomment-12789483 ---- This is an automatically sent email for [email protected]. To unsubscribe, please send an email to: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
