Error importing with Tailor in CSV mode

I get the following error message, when trying to import data into a Tailor content type (Blog post), using the backend web interface:

*"SQLSTATE[01000]: Warning: 1265 Data truncated for column 'relation_id' at row 1 (SQL: insert into `xc_0195da17262d425a997e843243dd25d4j` (`field_name`, `parent_id`, `relation_id`, `relation_type`) values (categories, 1, 42|47|49|83, Tailor\Models\EntryRecord@xc_482b0668d7d241cf87cb9b96cae75548c))" on line 760 of /var/www/html/vendor/laravel/framework/src/Illuminate/Database/Connection.php*

The CSV file I’m using to test is the same file that Tailor exports from the content type. So the tool is not able to import the same data that previously exported.

This is the context:

The blueprint of the content type:

uuid: 0195da17-262d-425a-997e-843243dd25d4
handle: Content\BlogPost
type: stream
name: Blog Post
drafts: false

    label: Content
    icon: octo-icon-file
    order: 100

    icon: icon-bookmark
    parent: Content\BlogPost
    order: 10


        tab: Meta Data
        type: mixin
        source: Content\BasicData
        tab: Meta Data
        label: Authors
        type: entries
        source: Content\Author
        commentAbove: 'Select the authors of this post'
        tab: Meta Data
        label: Main image
        type: fileupload
        mode: image
        maxFiles: 1
        tab: Meta Data
        label: Categories
        commentAbove: 'Select the categories this post belongs to'
        type: entries
        source: Content\Category    
        tab: Content
        label: Full text
        type: richeditor
        span: adaptive

Each Blog post could have several categories and authors, so these are the blueprints for those entities:

For authors:

uuid: ad40f25f-4485-486d-867f-87884dd08d7a
handle: Content\Author
type: entry
name: Author
drafts: false

    parent: Content\Category
    icon: icon-magic
    order: 6

        label: Description
        type: textarea
        size: small
        label: Photo
        type: mediafinder
        mode: image

For categories:

uuid: 482b0668-d7d2-41cf-87cb-9b96cae75548
handle: Content\Category
type: structure
name: Category
drafts: false

    maxDepth: 3

    label: Taxonomies
    icon: icon-table
    order: 101

    icon: icon-tree
    parent: Content\Category
    order: 5

        label: Description

Finally, this is the content of the basic CSV file, with only one record:

ID^Title^Slug^Status^Language^"Main image"^"Full text"^Categories^Authors^Enabled^"Publish Date"^"Expiry Date"^"Entry Type"
1^"Sample post"^sample-post^published^es^http://localhost:8082/storage/app/uploads/public/63e/2d7/ae3/63e2d7ae3eab1684532091.jpg^"<p>Lorem ipsum lorem ipsum Lorem ipsum lorem ipsum Lorem ipsum lorem ipsum Lorem ipsum lorem ipsum Lorem ipsum lorem ipsum </p>"^52|53|54|61^359|360^1^^^

Here I’m using ^ as a separator character. The result is the same when using a comma.

After excluding some fields, the export finishes without errors, but only the first category and author are loaded. So the list of ids separated by pipes is not working to load the relationships correctly.

Your suggestions will be greatly appreciated.

Did you try json? For me it works just perfect!

You are right. JSON works just fine. However, CSV import should work. I think it is a bug that should be fixed.

Best regards.