DataFrameReader.Jdbc Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Overloads
Jdbc(String, String, Dictionary<String,String>) |
Construct a DataFrame representing the database table accessible via JDBC URL url named table and connection properties. |
Jdbc(String, String, IEnumerable<String>, Dictionary<String,String>) |
Construct a DataFrame representing the database table accessible via JDBC URL url named table and connection properties. The predicates parameter gives a list expressions suitable for inclusion in WHERE clauses; each one defines one partition of the DataFrame. |
Jdbc(String, String, String, Int64, Int64, Int32, Dictionary<String,String>) |
Construct a DataFrame representing the database table accessible via JDBC URL url named table. Partitions of the table will be retrieved in parallel based on the parameters passed to this function. |
Jdbc(String, String, Dictionary<String,String>)
Construct a DataFrame representing the database table accessible via JDBC URL url named table and connection properties.
public Microsoft.Spark.Sql.DataFrame Jdbc(string url, string table, System.Collections.Generic.Dictionary<string,string> properties);
member this.Jdbc : string * string * System.Collections.Generic.Dictionary<string, string> -> Microsoft.Spark.Sql.DataFrame
Public Function Jdbc (url As String, table As String, properties As Dictionary(Of String, String)) As DataFrame
Parameters
- url
- String
JDBC database url of the form "jdbc:subprotocol:subname"
- table
- String
Name of the table in the external database
- properties
- Dictionary<String,String>
JDBC database connection arguments
Returns
DataFrame representing the database table accessible via JDBC
Applies to
Jdbc(String, String, IEnumerable<String>, Dictionary<String,String>)
Construct a DataFrame representing the database table accessible via JDBC URL url named table and connection properties. The predicates parameter gives a list expressions suitable for inclusion in WHERE clauses; each one defines one partition of the DataFrame.
public Microsoft.Spark.Sql.DataFrame Jdbc(string url, string table, System.Collections.Generic.IEnumerable<string> predicates, System.Collections.Generic.Dictionary<string,string> properties);
member this.Jdbc : string * string * seq<string> * System.Collections.Generic.Dictionary<string, string> -> Microsoft.Spark.Sql.DataFrame
Public Function Jdbc (url As String, table As String, predicates As IEnumerable(Of String), properties As Dictionary(Of String, String)) As DataFrame
Parameters
- url
- String
JDBC database url of the form "jdbc:subprotocol:subname"
- table
- String
Name of the table in the external database
- predicates
- IEnumerable<String>
Condition in the WHERE clause for each partition
- properties
- Dictionary<String,String>
JDBC database connection arguments
Returns
DataFrame representing the database table accessible via JDBC
Applies to
Jdbc(String, String, String, Int64, Int64, Int32, Dictionary<String,String>)
Construct a DataFrame representing the database table accessible via JDBC URL url named table. Partitions of the table will be retrieved in parallel based on the parameters passed to this function.
public Microsoft.Spark.Sql.DataFrame Jdbc(string url, string table, string columnName, long lowerBound, long upperBound, int numPartitions, System.Collections.Generic.Dictionary<string,string> properties);
member this.Jdbc : string * string * string * int64 * int64 * int * System.Collections.Generic.Dictionary<string, string> -> Microsoft.Spark.Sql.DataFrame
Public Function Jdbc (url As String, table As String, columnName As String, lowerBound As Long, upperBound As Long, numPartitions As Integer, properties As Dictionary(Of String, String)) As DataFrame
Parameters
- url
- String
JDBC database url of the form "jdbc:subprotocol:subname"
- table
- String
Name of the table in the external database
- columnName
- String
The name of a column of integral type that will be used for partitioning
- lowerBound
- Int64
The minimum value of columnName used to decide partition stride.
- upperBound
- Int64
The maximum value of columnName used to decide partition stride
- numPartitions
- Int32
The number of partitions. This, along with lowerBound (inclusive), upperBound(exclusive), form partition strides for generated WHERE clause expressions used to split the column columnName evenly.When the input is less than 1, the number is set to 1.
- properties
- Dictionary<String,String>
JDBC database connection arguments
Returns
DataFrame representing the database table accessible via JDBC