In Superset’s native UI, the Drill By option appears for charts, but when the same dashboard is embedded into a React application using the Superset Embedded SDK, the Drill By option is missing, even though hasDrillBy is set to true in dashboardUiConfig. #34631
Replies: 2 comments 4 replies
-
Hi @prsandeep! I'm Dosu and I’m helping the superset team. The Drill By feature is now officially supported in embedded dashboards as of Superset 4.1.1+ (PR #34319). However, its visibility in embedded mode does not depend on the Make sure your Superset backend is version 4.1.1 or later, and that the guest/embedded role used for the token has all the necessary permissions. Also, note that Drill By only appears for supported chart types and when the chart data structure allows it (i.e., grouped by dimension value) reference. If you’ve confirmed the above and still don’t see Drill By, check for version mismatches between your Embedded SDK and Superset backend, and ensure your chart type supports Drill By. Let me know if you need details on how to set these permissions. To reply, just mention @dosu. How did I do? Good | Irrelevant | Incorrect | Verbose | Hallucination | Report 🐛 | Other |
Beta Was this translation helpful? Give feedback.
-
Hi @dosu, thanks for the clarification. I’m using Superset v4.1.2 with @superset-ui/embedded-sdk v0.2.0. I’m embedding the dashboard in a React app using Admin credentials to generate the guest token, but the token’s "roles" is currently set to ["Admin"]. I’ll make sure this role has the required permissions (can_drill on Dashboard, can_write on ExploreFormDataRestApi, and can_samples on Datasource). I’ll verify that the charts I’m testing with are supported for Drill By and that there are no version mismatches between the SDK and backend. If I still face issues after setting the permissions, I’ll share the details with you. Thanks for the guidance! |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
import React, { useEffect, useRef, useState } from 'react';
import { useNavigate } from 'react-router-dom';
import { embedDashboard } from '@superset-ui/embedded-sdk';
import { bugzillaApi } from '../services/bugzillaApi'; // Import the separate API service
import '../bugzilla.css';
function BugzillaDashboard() {
const navigate = useNavigate();
const dashboardId = 'e191eb89-281d-4d10-8bcd-2dc415b9514e';
const containerRef = useRef(null);
const [loading, setLoading] = useState(true);
const [error, setError] = useState(null);
const [dashboardConfig, setDashboardConfig] = useState(null);
const handleGoBack = () => {
navigate(-1); // Go back to previous page
};
useEffect(() => {
const embedSupersetDashboard = async () => {
try {
setLoading(true);
setError(null);
}, [dashboardId]);
return (
{/* Back Button */}
<div style={{
position: 'absolute',
top: 10,
left: 10,
zIndex: 1000
}}>
<button
onClick={handleGoBack}
style={{
padding: '8px 15px',
background: '#6c757d',
color: 'white',
border: 'none',
borderRadius: '4px',
cursor: 'pointer',
fontSize: '14px',
display: 'flex',
alignItems: 'center',
gap: '5px'
}}
>
← Back
);
}
export default BugzillaDashboard;
Beta Was this translation helpful? Give feedback.
All reactions