Index: openacs-4/packages/file-storage/www/file-oracle.xql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/file-storage/www/Attic/file-oracle.xql,v diff -u -r1.2 -r1.3 --- openacs-4/packages/file-storage/www/file-oracle.xql 17 Aug 2001 14:49:05 -0000 1.2 +++ openacs-4/packages/file-storage/www/file-oracle.xql 20 Aug 2001 17:31:05 -0000 1.3 @@ -31,8 +31,7 @@ r.description, acs_permission.permission_p(r.revision_id,:user_id,'admin') as admin_p, acs_permission.permission_p(r.revision_id,:user_id,'delete') as delete_p, - -- dbms_lob.getlength(r.content) as content_size - r.content_length as content_size + dbms_lob.getlength(r.content) as content_size from acs_objects o, cr_revisions r where o.object_id = r.revision_id and acs_permission.permission_p(r.revision_id, :user_id, 'read') = 't' Index: openacs-4/packages/file-storage/www/file-postgresql.xql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/file-storage/www/Attic/file-postgresql.xql,v diff -u -r1.1 -r1.2 --- openacs-4/packages/file-storage/www/file-postgresql.xql 16 Aug 2001 20:33:11 -0000 1.1 +++ openacs-4/packages/file-storage/www/file-postgresql.xql 20 Aug 2001 17:31:14 -0000 1.2 @@ -31,8 +31,7 @@ r.description, acs_permission__permission_p(r.revision_id,:user_id,'admin') as admin_p, acs_permission__permission_p(r.revision_id,:user_id,'delete') as delete_p, - -- dbms_lob.getlength(r.content) as content_size - r.content_length as content_size + lob_length(r.lob) as content_size from acs_objects o, cr_revisions r where o.object_id = r.revision_id and acs_permission__permission_p(r.revision_id, :user_id, 'read') = 't' Index: openacs-4/packages/file-storage/www/file.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/file-storage/www/file.tcl,v diff -u -r1.2 -r1.3 --- openacs-4/packages/file-storage/www/file.tcl 16 Aug 2001 20:34:11 -0000 1.2 +++ openacs-4/packages/file-storage/www/file.tcl 20 Aug 2001 17:30:54 -0000 1.3 @@ -65,7 +65,11 @@ r.description, acs_permission.permission_p(r.revision_id,:user_id,'admin') as admin_p, acs_permission.permission_p(r.revision_id,:user_id,'delete') as delete_p, - -- dbms_lob.getlength(r.content) as content_size + -- JS: For now, we stick to the original version. According to DanW, we + -- JS: should take care of filling up content_length. Ideally, we want to abstract away + -- JS: the calculation of content_length independent of storage_type, so eventually this + -- JS: will just call the content_length attribute + dbms_lob.getlength(r.content) as content_size r.content_length as content_size from acs_objects o, cr_revisions r where o.object_id = r.revision_id Index: openacs-4/packages/file-storage/www/index-oracle.xql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/file-storage/www/Attic/index-oracle.xql,v diff -u -r1.1 -r1.2 --- openacs-4/packages/file-storage/www/index-oracle.xql 13 Aug 2001 01:07:30 -0000 1.1 +++ openacs-4/packages/file-storage/www/index-oracle.xql 20 Aug 2001 17:30:31 -0000 1.2 @@ -12,10 +12,7 @@ content_item.get_path(i.item_id,file_storage.get_root_folder(:package_id)) as path, r.mime_type as type, to_char(o.last_modified,'YYYY-MM-DD HH24:MI') as last_modified, - -- dbms_lob.getlength(r.content) as content_size, - -- instead of above, we rely on CR to calculate for us the size of - -- r.content. - r.content_length as content_size, + dbms_lob.getlength(r.content) as content_size, 1 as ordering_key from cr_items i, cr_revisions r, acs_objects o where i.item_id = o.object_id Index: openacs-4/packages/file-storage/www/index.tcl =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/file-storage/www/index.tcl,v diff -u -r1.2 -r1.3 --- openacs-4/packages/file-storage/www/index.tcl 13 Aug 2001 01:08:35 -0000 1.2 +++ openacs-4/packages/file-storage/www/index.tcl 20 Aug 2001 17:30:44 -0000 1.3 @@ -49,6 +49,10 @@ content_item.get_path(i.item_id,file_storage.get_root_folder(:package_id)) as path, r.mime_type as type, to_char(o.last_modified,'YYYY-MM-DD HH24:MI') as last_modified, + -- JS: For now, we stick to port of the original version. According to DanW, we + -- JS: should take care of filling up content_length. Ideally, we want to abstract away + -- JS: the calculation of content_length independent of storage_type, so eventually this + -- JS: will just call the content_length attribute dbms_lob.getlength(r.content) as content_size, 1 as ordering_key from cr_items i, cr_revisions r, acs_objects o