diff --git a/superset/viz.py b/superset/viz.py
index <HASH>..<HASH> 100644
--- a/superset/viz.py
+++ b/superset/viz.py
@@ -1601,13 +1601,18 @@ class SunburstViz(BaseViz):
 
     def get_data(self, df: pd.DataFrame) -> VizData:
         fd = self.form_data
-        cols = fd.get("groupby")
+        cols = fd.get("groupby") or []
         metric = utils.get_metric_name(fd.get("metric"))
         secondary_metric = utils.get_metric_name(fd.get("secondary_metric"))
         if metric == secondary_metric or secondary_metric is None:
-            df.columns = cols + ["m1"]  # type: ignore
+            df.rename(columns={df.columns[-1]: "m1"}, inplace=True)
             df["m2"] = df["m1"]
-        return json.loads(df.to_json(orient="values"))
+            cols.extend(["m1", "m2"])
+
+        # Re-order the columns as the query result set column ordering may differ from
+        # that listed in the hierarchy.
+        df = df[cols]
+        return df.to_numpy().tolist()
 
     def query_obj(self):
         qry = super().query_obj()
[fix] Ensure sunburst column ordering adheres to hierarchy (#<I>)