I'm interested in learning if it's possible to grab the results set from a
query run on an external database as opposed to grabbing the full table and
manipulating it later. The base code I'm working with is below (using Spark
2.0.0):
```
from pyspark.sql import SparkSession
df = spark.read\
Hi,
Don't think so.
Pozdrawiam,
Jacek Laskowski
https://medium.com/@jaceklaskowski/
Mastering Apache Spark 2.0 http://bit.ly/mastering-apache-spark
Follow me at https://twitter.com/jaceklaskowski
On Tue, Aug 2, 2016 at 10:25 PM, pgb wrote:
> I'm interested in learning if it's possible to
You don't need to get full table. This is getting data from an Oracle table
val c = HiveContext.load("jdbc",
Map("url" -> _ORACLEserver,0
"dbtable" -> "(SELECT to_char(CHANNEL_ID) AS CHANNEL_ID, CHANNEL_DESC FROM
sh.channels WHERE CHANNEL_ID <= 1000)",
"user" -> _username,
"password" -> _password)