-
Notifications
You must be signed in to change notification settings - Fork 40
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
Import pagedata to sites with multiple assignments #586
Comments
Hi there! Same problem here. I heavily try to create a merging/join from multiple tables to achieve having one huge table containing the information from several tables. Luckily there is the possibility to assign multiple tables to one page. BUT then I realized that I can't import data from csv into one of those tables without losing the other data. Obviously when data is imported into one table there is another empty row created in the other tables for this page where multiple tables are assigned to. I found kind of a workaround after inspecting the
I thought: yippie! The entries are displayed in aggregation BUT now i would need to enter the values again that they are shown on pages also. I am kind of baffled right now how to continue. There is lots of data to import via CSV in my case. Maybe someone could point me to any chance of solving this:
Any hint even at one of those questions would be highly welcome! |
My workaround for two schemas was also with sqlite:
|
Thank you sir! Deleting does the trick. With multiple schemas: |
Thanks a lot Matthias for your hint! I am not sure how long I would have struggled on this one otherwise... For the sake of completeness: Here comes my workaround that seems to do the job for multiple schemas assigned to one page ("respective schemas").
ad 5 & 6: When importing data to the empty schema the first entry is the wanted one. When importing data to another schema there is an empty data row added with same ''pid'' but a later ''rev''. The ''rev'' is a Unix timestamp for when the row was created. Therefore, the following SQL syntax deletes all rows of a ''pid'' that are not the oldest one. As I am not into depth of struct plugin nor a SQL programmer this code is at own risk. It can only be fired once, so if something went wrong proceed with point 3. At Linux server with installed ''sqlite3'' and ''bash'' (at least version 3) package:
Cheers! |
Phew, not really a solution for normal users |
If page (s) are assigned to several schemas, there is a problem with the csv import.
When importing into the first scheme, all data disappears from the other assigned schemes.
If you look in the sqlite tables, you can see that the data from the other schemas have also received a new revision - but without the data being adopted.
Of course, this only affects pages that are updated with the import.
I think an import into schema A should never touch data from schema B.
The text was updated successfully, but these errors were encountered: