mui / mui-toolpad

Toolpad: Full stack components and low-code builder for dashboards and internal apps.
https://mui.com/toolpad/
MIT License
951 stars 237 forks source link

Bring back SQL query preview #1973

Open prakhargupta1 opened 1 year ago

prakhargupta1 commented 1 year ago

Duplicates

Latest version

Summary 💡

Currently, a SQL query is written in a .sql file and run through a custom function. It currently shows up as:

Screenshot 2023-06-10 at 11 50 34 PM

screenshot from this app: http://localhost:3000/_toolpad/app/pages/9r8fshsf

We should still support writing SQL in the IDE only, just that the output can be a table view like:

Screenshot 2023-05-05 at 6 31 31 PM

Also, from the editor when a user chooses to write a SQL query, we can create a template for it. Related discussion: https://github.com/mui/mui-toolpad/discussions/2061

Examples 🌈

No response

Motivation 🔦

No response

oliviertassinari commented 1 year ago

A bit related to https://github.com/mui/mui-private/pull/256#discussion_r1245134278

oliviertassinari commented 1 year ago

When there is an error in the SQL error, the line number is unhelpful if written outside of a .sql file:

Screenshot 2023-06-28 at 14 40 58
JerryWu1234 commented 1 year ago

let me take a look

Janpot commented 1 year ago

@JerryWu1234 this one is not available for external contributors yet. it needs more shaping first.