diff --git a/packages/synapse-react-client/src/components/SqlDefinedTableEditor/SqlDefinedTableEditorModal.tsx b/packages/synapse-react-client/src/components/SqlDefinedTableEditor/SqlDefinedTableEditorModal.tsx index 4b601e298f..a7af76bc58 100644 --- a/packages/synapse-react-client/src/components/SqlDefinedTableEditor/SqlDefinedTableEditorModal.tsx +++ b/packages/synapse-react-client/src/components/SqlDefinedTableEditor/SqlDefinedTableEditorModal.tsx @@ -21,7 +21,10 @@ export default function SqlDefinedTableEditorModal( data: entity, isLoading: isEntityLoading, error: entityError, - } = useGetEntity(entityId) + } = useGetEntity(entityId, undefined, { + // Set the stale time to infinity because we don't want to refetch this in the middle of an edit + staleTime: Infinity, + }) const [sql, setSql] = useState('') useEffect(() => {