Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- val opts = Map(
- "url" -> "jdbc:postgresql://localhost:5433/sparkdb",
- "dbtable" -> "TextLogs",
- "user" -> "admin",
- "password" -> "mypassword"
- )
- val df = spark.
- read.
- format("jdbc").
- options(opts).
- load
Add Comment
Please, Sign In to add comment