put this code in the fucntions.php file
<?php
global $wpdb;
$allPosts = $wpdb->get_results("SELECT * FROM `wp_posts`");
foreach($allPosts as $post){
$content = RemoveShortcodes('/\[\/?et_pb.*?\]/', '', $post->post_content);
$wpdb->update(
'wp_posts',array('post_content' => $content),array( 'ID' => $post->ID )
);
}
function RemoveShortcodes($beginning, $end, $string) {
$beginningPos = strpos($string, $beginning);
$endPos = strpos($string, $end);
if ($beginningPos === false || $endPos === false) {return $string;}
$textToDelete = substr($string, $beginningPos, ($endPos + strlen($end)) - $beginningPos);
return RemoveShortcodes($beginning, $end, str_replace($textToDelete, '', $string));
}code credit : https://github.com/vidursingh96