This error always comes up when you are trying to import a wallet with old pruned data meaning it can't find any transactions from the current blockchain data.
This is my own solution that works to me but I do not know if it will work for you.
Try to disable the pruning mode first and close the Bitcoin core> Go to the blockchain data folder and delete all data and then open Bitcoin core again and enable prune mode again and let it sync.
Update here if it didn't work.