Skip to content
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

[fix](outfile/export) refactor the documents of Outfile and Export #1391

Merged
merged 4 commits into from
Jan 7, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
464 changes: 239 additions & 225 deletions docs/data-operate/export/export-manual.md

Large diffs are not rendered by default.

368 changes: 213 additions & 155 deletions docs/data-operate/export/outfile.md

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -130,6 +130,13 @@ INTO OUTFILE "file_path"
INTO OUTFILE "file:///home/work/path/result_";
```

#### Explanation of the returned results:

- **FileNumber**: The number of generated files.
- **TotalRows**: The number of rows in the result set.
- **FileSize**: The total size of the exported files in bytes.
- **URL**: The prefix of the exported file paths. Multiple files will be numbered sequentially with suffixes `_0`, `_1`, etc.

#### DataType Mapping

Parquet and ORC file formats have their own data types. The export function of Doris can automatically export the Doris data types to the corresponding data types of the Parquet/ORC file format. The following are the data type mapping relationship of the Doris data types and the Parquet/ORC file format data types:
Expand Down
29 changes: 29 additions & 0 deletions docs/sql-manual/sql-statements/Show-Statements/SHOW-EXPORT.md
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,35 @@ illustrate:
3. You can use ORDER BY to sort any combination of columns
4. If LIMIT is specified, limit matching records are displayed. Otherwise show all

The meaning of each column in the result returned by the `show export` command is as follows:

- JobId: The unique ID of the job
- Label: The label of the export job. If not specified in the export, the system will generate one by default.
- State: Job status:
- PENDING: Job pending scheduling
- EXPORTING: Data export in progress
- FINISHED: Job successful
- CANCELLED: Job failed
- Progress: Job progress. This progress is based on query plans. For example, if there are a total of 10 threads and 3 have been completed, the progress is 30%.
- TaskInfo: Job information displayed in JSON format:
- db: Database name
- tbl: Table name
- partitions: Specified partitions for export. An empty list indicates all partitions.
- column\_separator: Column separator for the export file.
- line\_delimiter: Line delimiter for the export file.
- tablet num: Total number of tablets involved.
- broker: Name of the broker used.
- coord num: Number of query plans.
- max\_file\_size: Maximum size of an export file.
- delete\_existing\_files: Whether to delete existing files and directories in the export directory.
- columns: Specified column names to export, empty value represents exporting all columns.
- format: File format for export
- Path: Export path on the remote storage.
- `CreateTime/StartTime/FinishTime`: Job creation time, scheduling start time, and end time.
- Timeout: Job timeout time in seconds. This time is calculated from CreateTime.
- ErrorMsg: If there is an error in the job, the error reason will be displayed here.
- OutfileInfo: If the job is successfully exported, specific `SELECT INTO OUTFILE` result information will be displayed here.

### Example

1. Show all export tasks of default db
Expand Down
Loading
Loading