Hi @Shruti Gupta
Since you have I tried with all the versions that comes with an MSI installer in the releases page of npgsql, I suggest you change the way, try using postgreSQL ODBC driver to connect to Postgres database.
The references I find:
Connect to a PostgreSQL database through ODBC on Excel 2016
Hope the information could he helpful.
If the answer is helpful, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".
Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.