PySpark and Postgres: JDBC connection error
Seems like your URL is missing a : character.
You've written
jdbc:postgresql//localhost...

instead of
jdbc:postgresql://localhost...


Issues connecting PySpark & Postgres
I've scoured the Apache docs, Stackoverflow and watched youtube tutorials but can't seem to find an issue to my exact issue. I have clearly pointed to the postgres executable jar file but it doesn't I can't seem to be able to read from the db. Below is an extract from my script. The properties parameter contains the user, password and driver ("org.postgresql.Driver") details in the form of a dictionary.
Anybody know what I am missing? I get the error:

IllegalArgumentException: requirement failed: the driver could not open a JDBC connection. Check the URL

Added context: I am using Postgres 15, Spark 3.4.0 and Python 3.10
spark = SparkSession\
        .builder\
        .config('spark.jars','C:\Program Files\Spark\spark-3.4.0-bin-hadoop3\jars\postgresql-42.6.0.jar')\
        .getOrCreate()

    spark.read.jdbc(
        url=f'jdbc:postgresql//localhost:5432/ag',
        table='customers',
        properties=props).load()

