Views:

Question:
How to calculate subdirectories in DocuWare File Cabinets?

Answer:
Calculating the individual subdirectories can be conducted using the following mathematic formulas:
X: File Number (:=Document-ID :=Record-ID)
1. Subdirectory Level: x / (256 * 256 *256)
2. Subdirectory Level: x / (256 * 256)
3. Subdirectory Level: (x/256) AND 255

Example:
The document page with the number 125876 should be stored:
1. Subdirectory: 125876 / (256 * 256 * 256) = 0.0075 => 000 (since no fractions can be used in integer arithmetic, it is rounded to the next whole number).

2. Subdirectory: 125876 / (256 * 256) = 1.92 => 001 (since no fractions can be used in integer arithmetic, it is rounded to the next whole number).
3. Subdirectory: 125876 / (256) AND 255 = 491 AND 255 = 235 => 235 (integer arithmetic always guarantees that the result of the division remains whole AND represents mathematic addition/AND link:

The path for the file to be stored is as follows:
D:\DOCS\PERSONAL.000001/000/001/235/0000125876/0000125876.xml
D:\DOCS\PERSONAL.000001/000/001/235/0000125876/f0.DWTiff