select creation_user as homework_user_id from acs_objects where object_id = :homework_file_id
select r.title
from cr_revisions r, cr_items i
where i.item_id = :file_id
and i.content_type = 'file_storage_object'
and r.revision_id = i.live_revision
update cr_revisions
set content = :tmp_filename,
content_length = :tmp_size
where revision_id = :revision_id
select f.name, folder.label as folder_name,
u.first_names || ' ' || u.last_name as student_name
from cr_items f, cr_folders folder, cc_users u, acs_objects o
where f.item_id = :file_id
and o.object_id = :file_id
and folder.folder_id = :folder_id
and u.user_id = o.creation_user
select f.name, folder.label as folder_name,
u.first_names || ' ' || u.last_name as admin_name
from cr_items f, cr_folders folder, cc_users u
where item_id = :homework_file_id
and folder.folder_id = :folder_id
and u.user_id = :user_id