On 13 мар, 13:17, [EMAIL PROTECTED] (Stuart White) wrote: > I have a bunch of documents that I need to import into a proprietary > database. The database has a table with key words, specifically, names of > people. This database software will import documents, but will not search > those documents for these key words, and then let me know which documents > talk about which people and on which page. Specifically, I would like to see > in the "referenced in document" field of the record for Joe Smith, a number > that represents all the documents Joe Smith is referenced in. Then, that > field is linked to another table, a Documents table, that shows me the names > of each document Joe Smith is referenced in, and the page number. My > database program already does this second part, but I have to manually do the > first part, the reading of the document, marking in the Joe Smith record that > he is in that document. I prefer not to do that. I still have to read the > documents anyway, and I still would have to read them for proper > nouns that refer to Joe Smith, or Mr. Smith, or Joe, but I'd like for some > of my work to be done by a program. > > That said, can perl search on a document for these key words, and then > populate my database in that fashion? The database software I am using is > called CaseMap. I recognize that I might need to find a module for CaseMap > so that perl can talk to it (at least, I think that's what I would need to > do).
There are two distinct problems here: - parsing documents - talking to the database First problem mostly depends on the format of your documents, and how easy it is to formalize the rules of recognizing relevant parts of documents for your purposes. So I would say, this is about getting clear requirements and coming up with an algorithm. Second problem is mostly a technical one. Usually it is quite easy to work with databases from Perl, but I have never heard of a module for Perl to talk to CaseMap. You may end up preparing some intermediate files in a format, that can be imported into CaseMap, or talking to some other popular DB from Perl and exporting-importing into your CaseMap. I suspect that CaseMap must have some tools for importing data. Good luck. -sandy http://myperlquiz.com/ -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org/