not able delete all products using cli
-
i’ve 30k active products and 1k in trash, i want to delete all the products including trash.
for active products i’m trying this command :
wp post delete $(wp post list --post_type='product' --format=ids) --force --allow-rootbut getting this in return :
usage: wp post delete <id>... [--force] [--defer-term-counting]same for trash products :
wp post delete $(wp post list --post_status=trash --format=ids) --allow-rootgetting same error :
usage: wp post delete <id>... [--force] [--defer-term-counting]can anyone help me to figure out this issue
edit :
wp wc product delete <id> --user=admin --allow-rootwhile above command works fine but i want to delete products in bulk and this deletes single product only
The topic ‘not able delete all products using cli’ is closed to new replies.