Currently, the closest you can get to
native support for PostgreSQL on Google's Cloud Platform is Cloud PostgreSQL, but its still in beta and last I checked it is not natively supported by Apps Script's JDBC API (at least not yet).
However, its possible set up a Google Cloud function to act as an intermediary between Apps Script and your PostgreSQL database. But you'll have to create a custom community connector to integrate it with Datastudio.