Skip to content

Commit 861cc36

Browse files
Minor/Doc: Clarify DataFrame::write_table Documentation (#8519)
* update write_table doc * fmt
1 parent 2919e32 commit 861cc36

File tree

1 file changed

+9
-4
lines changed
  • datafusion/core/src/dataframe

1 file changed

+9
-4
lines changed

datafusion/core/src/dataframe/mod.rs

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1013,11 +1013,16 @@ impl DataFrame {
10131013
))
10141014
}
10151015

1016-
/// Write this DataFrame to the referenced table
1016+
/// Write this DataFrame to the referenced table by name.
10171017
/// This method uses on the same underlying implementation
1018-
/// as the SQL Insert Into statement.
1019-
/// Unlike most other DataFrame methods, this method executes
1020-
/// eagerly, writing data, and returning the count of rows written.
1018+
/// as the SQL Insert Into statement. Unlike most other DataFrame methods,
1019+
/// this method executes eagerly. Data is written to the table using an
1020+
/// execution plan returned by the [TableProvider]'s insert_into method.
1021+
/// Refer to the documentation of the specific [TableProvider] to determine
1022+
/// the expected data returned by the insert_into plan via this method.
1023+
/// For the built in ListingTable provider, a single [RecordBatch] containing
1024+
/// a single column and row representing the count of total rows written
1025+
/// is returned.
10211026
pub async fn write_table(
10221027
self,
10231028
table_name: &str,

0 commit comments

Comments
 (0)