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

Add missing information for the customized files importing doc #11943

Open
shenli opened this issue Jan 9, 2023 · 1 comment
Open

Add missing information for the customized files importing doc #11943

shenli opened this issue Jan 9, 2023 · 1 comment
Assignees
Labels
area/tidb-lightning Indicates that the Issue or PR belongs to the area of TiDB Lightning.

Comments

@shenli
Copy link
Member

shenli commented Jan 9, 2023

File: /release-6.1/tidb-lightning/tidb-lightning-data-source.md

Importing customized csv files needs more configuration, such as the pattern of table/schema DDL file name, such as:
`
[[mydumper.files]]
pattern = '^(test1).(tbl1)-schema.sql'
schema = "$1"
table = "$2"
type = "table-schema"

[[mydumper.files]]
pattern = '^(test1)-schema-create.sql'
schema = "$1"
type = "schema-schema"
`
Without the patterns for table/schema DDL file, users will meet a "schema not found" error if the table/schema are not created in advance.

@ran-huang ran-huang self-assigned this Jan 9, 2023
@ran-huang ran-huang added the area/tidb-lightning Indicates that the Issue or PR belongs to the area of TiDB Lightning. label Jan 9, 2023
@ran-huang
Copy link
Contributor

According to @niubell, this is by design. If there is no schema file and the table has not been created beforehand, an error message will be displayed to inform the user.
cc @Frank945946

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/tidb-lightning Indicates that the Issue or PR belongs to the area of TiDB Lightning.
Projects
None yet
Development

No branches or pull requests

2 participants