NOTE: When using some of these techniques, it is very easy to commit mass errors. Please use VERY CAREFULLY. If in doubt, ask a programmer to do it.
Updating an Area of UV (When Doing Mass Updates)
1. Go to MechGens
• Click on the third tab (LibraryMtceTasks)
• Type in Book#
• CopyTbl
2. Open a new Spreadsheet
• Paste table in the spreadsheet
• Add a new column for the area that you want to update (or not, if it's already there)
• In a column to the right, type in this code: =CONCAT("BOOKS,",A2,",(77),(",I2,")")
|
1
|
=CONCAT("BOOKS,",A2,",(77),(",I2,")") You are updating a book. Because of the quotation marks, this is literal. It's adding in the word BOOKS. You need that.
|
|
2
|
=CONCAT("BOOKS,",A2,",(77),(",I2,")") This is the column and the row that contains the articleID#
|
|
3
|
=CONCAT("BOOKS,",A2,",(77),(",I2,")") Note where the "" begins and ends. This is literal. 77 stands for the reference field in UV (where primary references are entered, not secondary references). Yes, you need the parentheses and comma added. You will need to change this part of the equation, depending on what you are doing. Double-check it!
|
|
4
|
=CONCAT("BOOKS,",A2,",(77),(",I2,")") I2 is the column that your References (or whatever) that you are trying to update are coming from. You will need to change this part of the equation, depending on what you are doing. Double-check it!
|
|
5
|
=CONCAT("BOOKS,",A2,",(77),(",I2,")") You need your final quotation marks around the ) and you need to have the final ) or the statement isn't done.
|
• Click and drag down.
3. Go to X:\Computer\eBooks\Applib - Apps
• Open MDHTools
• Click on "Call UV Subroutine"
• Click on update.uv.field
• Copy the column you created from step 2 into the second box down in the screen.
• Click run (it should be on BTP)
• Check the box at the bottom to make sure they are all successfully updated.
Other:
If you don't know what the number of the field you are updating is:
1. Go to X:\Computer\eBooks\Applib - Apps
2. Open QryMgr
• On the right, click FileMap
• Scroll down through the field names (D can have data entered into it, I is an info field and you can’t edit it)
• The number in the Nbr field is the one you want.
Commonly Used Fields and Their Numbers
|
|
Field Number
|
|
TITLE
|
3
|
|
TYPE
|
2
|
|
COVER
|
6
|
|
INVERT
|
13
|
|
PAGES
|
18
|
|
LANGUAGE
|
29
|
|
SUBTITLE
|
33
|
|
KIND
|
83
|
|
PARENT
|
84
|
|
VOLUME
|
85
|
|
AUTHOR
|
4
|
|
Reference
|
77
|
|
Illustrations
|
131
|
|
Quotes
|
133
|
|
Poetry
|
128
|
|
TYPE
|
2
|
|
TITLE
|
3
|
|
AUTHOR
|
4
|
|
COVER
|
6
|
|
INVERT
|
13
|
|
TYPE.SUB
|
17
|
|
KIND
|
83
|
|
WEB.TITLE.LIB
|
170
|
|
WEB.TITLE.INV
|
171
|
|
WEB.TITLE.SORT1
|
172
|
|
WEB.AUTHOR1
|
173
|
|
WEB.AUTHOR.INV
|
174
|
|
BTYPE
|
184
|
|
AUTHOR2
|
79
|
Creating an Author Record and Author Collection
For an Author Collection to exist, there must first be an Author Record. Follow the steps below to determine if an Author Record exists, then create one if it does not. After that, proceed on to creating a New Author Collection.
To create Collection Recs and Book Recs MDH uses the following Spreadsheet:
X:\People\Mark Hapanowicz\MDH Files\UV SQL Generator.xlsx
New Author Record – DO FIRST
If it's a new Author (not already in the Author's file)
Check related apps in Mechgens
1. Auth
• Search to see if the author record exists
~ In the AID field, type @ and the author’s name (sometimes it’s better to only search part of the name)
2. If it already exists, carry on to Author Collection Creation. If not,
• Go to the spreadsheet
• Put an N in col Z
• Copy Col Y
• Go to the MDH Tools app, then Call Subroutines -> UPDATE.UV.FIELDS
1. Paste the Col Y info into the second text box
2. hit the run button
3. capture the new Author Id
• paste the new author id back into the Col Z of the SQL Gen spreadsheet on the appropriate row.
• Make sure the Author in the BOOKS rec matches either the NAME, FULL.NAME or INITIALS in the AUTHORS file.
~ The AUTHORS screen can be found in MechGens App;Related Apps Tab, Doubleclick on AUTH
~ Or you can run the following from the QryMgr App or from the UV > prompt: SELECT AID, NAME, FULL.NAME, INITIALS, VARIANTS, WEB.OK, NOTES FROM AUTHORS WHERE AID = nnn ;
3. If it already exists as an author record, make sure you add the author id into the appropriate field in the spreadsheet.
New Author Collection – DO SECOND
In the case of Author Collections Records, in the spreadsheet use tab "Author Collection—New"
• Fill in the Author info in Cols A-F and Z
• Drag down all other columns up to V
• If it's a new collection, put an N in the Book column (G).
• Copy the V column
• Go to the MDH Tools app; Call Subroutines; UPDATE.UV.FIELDS
1. Paste the Col V info into the second text box
2. hit the run button
3. capture the new BookId
• paste the new book id back into the Col G of the SQL Gen spreadsheet on the appropriate row.