-
Notifications
You must be signed in to change notification settings - Fork 29k
[SPARK-29444][FOLLOWUP] add doc and python parameter for ignoreNullFields in json generating #26227
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from 1 commit
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -1189,9 +1189,10 @@ object SQLConf { | |
|
|
||
| val JSON_GENERATOR_IGNORE_NULL_FIELDS = | ||
| buildConf("spark.sql.jsonGenerator.ignoreNullFields") | ||
| .doc("If false, JacksonGenerator will generate null for null fields in Struct.") | ||
| .stringConf | ||
| .createWithDefault("true") | ||
| .doc("Whether to ignore null fields in column/struct during json generating. " + | ||
|
||
| "If false, json generator will generate null in Column/Struct.") | ||
| .booleanConf | ||
| .createWithDefault(true) | ||
|
|
||
| val FILE_SINK_LOG_DELETION = buildConf("spark.sql.streaming.fileSink.log.deletion") | ||
| .internal() | ||
|
|
@@ -2385,7 +2386,7 @@ class SQLConf extends Serializable with Logging { | |
|
|
||
| def sessionLocalTimeZone: String = getConf(SQLConf.SESSION_LOCAL_TIMEZONE) | ||
|
|
||
| def jsonGeneratorIgnoreNullFields: String = getConf(SQLConf.JSON_GENERATOR_IGNORE_NULL_FIELDS) | ||
| def jsonGeneratorIgnoreNullFields: Boolean = getConf(SQLConf.JSON_GENERATOR_IGNORE_NULL_FIELDS) | ||
|
|
||
| def parallelFileListingInStatsComputation: Boolean = | ||
| getConf(SQLConf.PARALLEL_FILE_LISTING_IN_STATS_COMPUTATION) | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -687,6 +687,8 @@ final class DataFrameWriter[T] private[sql](ds: Dataset[T]) { | |
| * <li>`encoding` (by default it is not set): specifies encoding (charset) of saved json | ||
| * files. If it is not set, the UTF-8 charset will be used. </li> | ||
| * <li>`lineSep` (default `\n`): defines the line separator that should be used for writing.</li> | ||
| * <li>`ignoreNullFields` (default `true`): whether to ignore null fields in column/struct | ||
| * during json generating. </li> | ||
|
||
| * </ul> | ||
| * | ||
| * @since 1.4.0 | ||
|
|
||
Uh oh!
There was an error while loading. Please reload this page.