That Solomon understood human suffering seems evident because of what he said in prayer at the inauguration of the temple of Jehovah.
وَلَوْ نَجَحَ فِي مَسْعَاهُ ،‏ لَعَنَى ذلِكَ دُونَ شَكٍّ ٱلْمَوْتَ لِسُلَيْمَانَ .‏