Get the result of a stored procedure to a dataframe or Rdd?

Viewed 5082

How to create a data frame from the result of a stored proc?

  val jdbcDf = sqlContext.read.format("jdbc").options(Map(
    "driver" -> "com.microsoft.sqlserver.jdbc.SQLServerDriver",
    "url" -> jdbcSqlConn,
    "dbtable" -> "(exec aStoredProc) a" // Error
  )).load()
1 Answers
Related