We are getting ready to import patron data into evergreen (ver.1.4-rc2) on a Ubuntu 8.04 system and I would like to ask a few questions to make sure I have the procedures correct for this process.
I asked this question many months ago and received a good starting tip to create a staging table in postgresql and import the data into that table. Then, I need to map the data to the corresponding table(s)in Evergreen. OK here are my questions regarding this process: 1. From looking at the database schema at: http://open-ils.org/documentation/evergreen_1.1.3_erd.html, It seems that a patron load will need to populate the tables: actor.card, actor.usr, and actor.usr_address. Could someone verify that this is a correct assumption on my part? 2. Should the staging table be in the actor schema or outside the schema or does it matter? 3. should the staging table represent the exact structure as the import file or should I restructure the data to fit into the evergreen system. In other words, do I maintain the field names of the file or change them? Moreover, some of the fields which cannot be null in evergreen are null in the data file. For example, the country field is blank for some records. Do I use the staging table to fill in these fields with default data (e.g. use "Canada" as default country). 3. I am not quite sure how mapping works in Postgresql to get the staging table data into the correct tables. Could someone send an example SQL statement to accomplish this or a link to the appropriate postgresql manual page which discusses this topic. 4. We have some "bonus" data in our patron file such as "program number" and "program name" to capture the students program of study. Is there a table we can store this in to use later? The table actor.usr_setting looked like a table to use for this, but I am not sure. Just to give you some background for our process (which might help others in thinking about this issue) here is the process we expect to set up for patron imports: 1. Our IT department will export student data from the student Oracle database into a csv (comma delimited file) file. 2. They will ftp the file to our evergreen server. 3. A script on the server will import the data into the staging table on Evergreen and map the data to the appropriate tables in evergreen. We are thinking that the data load each semester will only add new users which do not exist in Evergreen. We were debating whether it is better to load only the new patrons or certain fields for all patrons to capture things such as address changes. Any tips on this would be greatly appreciated since we are still unsure. Thanks, Robert This E-mail contains privileged and confidential information intended only for the individual or entity named in the message. If the reader of this message is not the intended recipient, or the agent responsible to deliver it to the intended recipient, you are hereby notified that any review, dissemination, distribution or copying of this communication is prohibited. If this communication was received in error, please notify the sender by reply E-mail immediately, and delete and destroy the original message.
