Forum .LRN Q&A: Re: Download Archive link throws an error when you have XoWiki pages

parent_id == -100 is ok, it means that the xowiki-folder is
not under the fs-folder, which is correct. 
So how does the file-store find some xowiki pages? 
Maybe, there are some xowiki-pages in the wrong folder? 

You should figure out the folder_id of the file-storage and do

  select item_id, name, content_type, storage_type  
  from cr_items where parent_id = 2533;

So far, i have not seen this, we are using xowiki-portlet in
various version in production since beginning and have not 
seen a problem there.

Hi Gustaf,

Thanks for the help and I'm sorry for the late answer. I've done the investigation just like you told me. I've found the community folder_id, and this is what I've found:

item_id | name | content_type | storage_type
---------+------------------------+------------------+--------------
108765 | ::3758 | ::xowiki::Object | text
108767 | en:index | ::xowiki::Page | text
573010 | arquivo-antigo | content_folder | text
20233 | software-cacic | content_folder | text
39706 | hist-rico-do-bate-papo | content_folder | text
3759 | public | content_folder | text

It seems like there are some XoWiki objects inside the community folder. The funny thing is: when I go to XoWiki administration page and look for its objects, the instance object is ::4247, what means that this Xowiki object doesn't exist in the community instance. And I've also tried to erase the folders manually and download it again, but the error is still there.

Any clue?

Ok, this is the problem. The main question is, how they get there. When i look at the item_ids, the two entries appear quite old. In a next step, i would recommend to output as well the creation_date and the package_id to figure the age and the xowiki instance. If these are quite old, this might have been some unknown earlier bug. If you find fresh entries, one should track the problem down.

The following query will list on your site all xowiki pages which are in in folders together with other folders:

select a.item_id, a.name, b.name, a.parent_id
from cr_items a, cr_items b,cr_folders f
where a.parent_id = f.folder_id and b.parent_id = f.folder_id
and a.content_type like '::%' and b.content_type = 'content_folder';

Ok, these are the query results. The first one, with creation_date:

item_id | name | content_type | storage_type | creation_date
---------+------------------------+------------------+--------------+-------------------------------
20233 | software-cacic | content_folder | text | 2007-02-23 10:19:54.19227-03
108765 | ::3758 | ::xowiki::Object | text | 2007-03-30 12:00:06.974362-03
108767 | en:index | ::xowiki::Page | text | 2007-03-30 12:00:07.064489-03
573010 | arquivo-antigo | content_folder | text | 2007-05-02 14:04:41.461104-03
39706 | hist-rico-do-bate-papo | content_folder | text | 2007-03-14 18:30:33.551438-03
3759 | public | content_folder | text | 2007-02-06 11:17:18.221666-03

Now the second one that you suggested with creation_date too:

item_id | name | name | parent_id | creation_date
---------+-----------+------------------------+-----------+-------------------------------
108765 | ::3758 | arquivo-antigo | 3758 | 2007-03-30 12:00:06.974362-03
108767 | en:index | arquivo-antigo | 3758 | 2007-03-30 12:00:07.064489-03
108765 | ::3758 | public | 3758 | 2007-03-30 12:00:06.974362-03
108767 | en:index | public | 3758 | 2007-03-30 12:00:07.064489-03
108765 | ::3758 | software-cacic | 3758 | 2007-03-30 12:00:06.974362-03
108767 | en:index | software-cacic | 3758 | 2007-03-30 12:00:07.064489-03
108765 | ::3758 | hist-rico-do-bate-papo | 3758 | 2007-03-30 12:00:06.974362-03
108767 | en:index | hist-rico-do-bate-papo | 3758 | 2007-03-30 12:00:07.064489-03
523419 | ::5657 | Arquivos do sisau | 5657 | 2007-04-26 17:00:57.975437-03
523421 | en:index | Arquivos do sisau | 5657 | 2007-04-26 17:00:58.193165-03
523419 | ::5657 | public | 5657 | 2007-04-26 17:00:57.975437-03
523421 | en:index | public | 5657 | 2007-04-26 17:00:58.193165-03
1491998 | en:index | curso-eproinfo | 31218 | 2007-08-15 01:28:39.608321-03
1491998 | en:index | public | 31218 | 2007-08-15 01:28:39.608321-03
464380 | ::51437 | sgd-1-0 | 51437 | 2007-04-23 15:20:24.41398-03
464382 | en:index | sgd-1-0 | 51437 | 2007-04-23 15:20:24.576715-03
464380 | ::51437 | public | 51437 | 2007-04-23 15:20:24.41398-03
464382 | en:index | public | 51437 | 2007-04-23 15:20:24.576715-03
464380 | ::51437 | new-folder-4206473 | 51437 | 2007-04-23 15:20:24.41398-03
464382 | en:index | new-folder-4206473 | 51437 | 2007-04-23 15:20:24.576715-03
464380 | ::51437 | new-folder | 51437 | 2007-04-23 15:20:24.41398-03
464382 | en:index | new-folder | 51437 | 2007-04-23 15:20:24.576715-03
2272500 | ::560894 | artigos-para-publica-o | 560894 | 2007-11-14 13:44:46.059727-03
2272500 | ::560894 | site | 560894 | 2007-11-14 13:44:46.059727-03
2272500 | ::560894 | public | 560894 | 2007-11-14 13:44:46.059727-03
3772749 | ::3390856 | new-folder-3654118 | 3390856 | 2008-04-16 11:58:51.743952-03
3772749 | ::3390856 | new-folder | 3390856 | 2008-04-16 11:58:51.743952-03