Excel \ MODX ImportX

Hey guys. Tell me how to transfer data from Excel to modx revo. If there are categories and subcategories?

What exactly do you mean by that?

Do you mean importing resources with the folder structure (from the resource tree), so that the “parent” field is set correctly after the import?

Hello. Transfer data from Excel to a tree
2023-02-17_193606

ImportX will accept parents defined in a parent column, but you will need to prepare the spreadsheet in Excel to have that set correctly, and may need to first import all your categories before importing subcategories separately with the parents set to the IDs that were assigned to them by MODX.

Hello. I did something wrong…Just worth the text :

“The console is running…
Attempted to set execution time to infinite. Max execution time currently: infinite.
Testing the data before importing…
The data from the CSV file will replace all the data entered manually. File name: Book1.xlsx”
For a long time, nothing happens.
111

So is this an Excel file?
I believe the data should be a CSV and not an Excel file.

hello. of course! you’re right. I didn’t pay attention… however, I try it for the first time, it does not work. there are errors now.
Error: tvcod (cod must be an integer)
Error: tvprice (price must be an integer).
It seems to me that everything is OK with numbers. What does he want?

Use the ID of the template variable (and NOT the name).

If your TV with the name “cod” has the ID = 3, then name the column “tv3”.

Thanks. Guys, help out. I don 't understand what it is .
Now: The console is running…
Attempted to set execution time to infinite. Max execution time currently: infinite.
Testing the data before importing…
The data from the CSV file will replace all the data entered manually. File name: 1.csv
No errors were found. Preparing the data for import…
Error: The number of elements does not match. Please check the syntax in line 31.
I tried hiding the fields, using basic I limited the number of rows. Anyway, every time the error is line 31. I tried different CSV formats


Check your data on line 31.

Maybe there is a ; or , in the text, so that the amount of columns doesn’t match the amount of columns in the header row.

Or make sure there is no empty line at the end of the document.

hello. does not work. cgfcb,j/ I do it via notepad++