get fileid before getting metadata