Last week I needed to bulk import a large number of files into a Notes document library. The client had already organised the files, and so they wanted that file system structure (which was many levels deep) duplicated when the files were imported into the document library.
Sounds simple, but I was quite surprised that I couldn’t find a code snippet out there which did what I was after – surely this is a fairly common requirement? So after a few minutes of looking I gave up searching and wrote my own 10 minute bulk import agent in Java.
Here it is in case anyone else finds it useful.
I’ve never actually written any Java before so I’m sure it’s not ideal in some ways, and it’s a bit rough around the edges, but it did the job in my case.
Why did I choose Java? Well, I’ve been curious for a while about how much my C# skills translate into Java, and the fact that it took me 10 minutes to do what I needed sort of proves that the translation is indeed simple. I initially started writing this in LotusScript, but it just seemed smarter and easier to do it using Java’s file I/O classes compared to the LotusScript approach.
Hope someone else out there finds it useful.
Tags: Lotus, Notes, Domino, Data import