Hi, I have an unusual request from a customer where they need to locate a particular file in Laserfiche based on the volume File Path, e.g. "e00\00\03\00000362". This is because their anti-virus software have detected a virus (probably) in the volume files and they want to make sure is not a false alarm before removing the file. Is there anyway we can locate this file inside Laserfiche based on the file path given? Thanks.
Question
Question
Locating File in Laserfiche based on File Path in Volume
Answer
Files found in a subfolder of the e## folders, as in your example, are electronic files and you should use the SQL query provided by Scott. Then you use the tocid as the Entry ID in the LF client search for Entry ID
The files found in the subfolders of ## folders are your Laserfiche document pages and you would use a search like:
SELECT doc.tocid FROM doc INNER JOIN toc ON doc.tocid = toc.tocid INNER JOIN vol ON toc.vol_id = vol.vol_id WHERE (vol.vol_name = N'XXXXXX') AND (doc.storeid = Y)
Replace XXXXXX with the Volume Name (found as the Folder above the ## folder
Replace the Y with the decimal equivalent of the Hex document name. Use a Programmer calculator in Hex mode to enter the Hex (without leading zeros) to get the decimal conversion.
Replies
If you have access to SQL, you should be able to search the "toc" table for a "edoc_storeid" of 866 (comes from converting 362 hexadecimal into decimal). You may also want to include the volume in your search. You would have to find the volume ID of the relevant volume from the "vol" table. Altogether, your query would be something like:
SELECT * FROM toc WHERE edoc_storeid = 866 AND vol_id=X
That would give you the entry name (if the entry exists in your system). Easiest thing to do would be search your entire repository for that entry name to find the document in question. You could also figure out the path in SQL if you prefer. Each entry also has a tocid and a parentid. A parentid is just a reference to another tocid in the toc table, which would be the parent folder of the current entry. You can use this to track the folder structure back to the root level.
If you have access to the volumes, you could always locate the file by following the directory path. I don't think there is advance search syntax that would allow you to do it from in Laserfiche client.
That works! Many thanks for all your support.