diff --git a/superset-frontend/src/SqlLab/actions/sqlLab.js b/superset-frontend/src/SqlLab/actions/sqlLab.js index 8124907a3..18d2141bf 100644 --- a/superset-frontend/src/SqlLab/actions/sqlLab.js +++ b/superset-frontend/src/SqlLab/actions/sqlLab.js @@ -987,7 +987,9 @@ export function mergeTable(table, query) { function getTableMetadata(table, query, dispatch) { return SupersetClient.get({ endpoint: encodeURI( - `/api/v1/database/${query.dbId}/table/${table.name}/${table.schema}/`, + `/api/v1/database/${query.dbId}/table/${encodeURIComponent( + table.name, + )}/${encodeURIComponent(table.schema)}/`, ), }) .then(({ json }) => {