[REQ] Batch Editing for Writer, Composer Fields?
[REQ] Batch Editing for Writer, Composer Fields?
The writer and composer fields have become available in v4.2.0.2, but I had a collection running over 3000 titles in AMC before that version was released. To import or fill in the writer and composer individually for each title would be cumbersome and extremely time-consuming.
Is there a way to batch edit or import data for selected titles, say a hundred selected files in one go, for selected fields such as writer/composer? If yes, I'd love to have some information on how to do that. If such an option does not exist, then it may perhaps be worth considering as another feature to add for the next release.
Looking forward to some ideas on this.
Is there a way to batch edit or import data for selected titles, say a hundred selected files in one go, for selected fields such as writer/composer? If yes, I'd love to have some information on how to do that. If such an option does not exist, then it may perhaps be worth considering as another feature to add for the next release.
Looking forward to some ideas on this.
I want to add data to the "Writer" and "Composer" fields for about 2500 titles. If it is possible to add that data for 100 films in one step by choosing one set of options that'll do the work. Importing can take as long as necessary as long as one doesn't have to import separately for every single title.
I have the IMDB and other scripts (F6 option, have also tried Shift+F6 without success), but I haven't been able to run those scripts for more than one title at one time. And that means that in order to fill in writer/composer for 2500 titles I'll have to run the IMDB script 2500 times! It is possible to select multiple titles and run the scripts but the import has to be clicked separately for each title. The whole process takes so much time that adding 2 or 3 values via manual copy-paste would be quicker.
Is there a quicker way to do this for writer, composer, certification?
I have the IMDB and other scripts (F6 option, have also tried Shift+F6 without success), but I haven't been able to run those scripts for more than one title at one time. And that means that in order to fill in writer/composer for 2500 titles I'll have to run the IMDB script 2500 times! It is possible to select multiple titles and run the scripts but the import has to be clicked separately for each title. The whole process takes so much time that adding 2 or 3 values via manual copy-paste would be quicker.
Is there a quicker way to do this for writer, composer, certification?
To apply a script to more than one movie, select these movies before opening the script window.
In that window there is also an option ("movies to include", on the right) where you can specify that you want to apply to all movies rather than selection.
Then when the IMDb script is selected, on the right you have some options. One is "Batch mode". It allows to suppress confirmation dialogs and use the IMDb URL from the URL field instead of doing a title search. But as I said previously, to have this working fine the movies must have the IMDb URL stored there (I assume it is the case?) so the script can fetch the right movie info without having to ask you to confirm the title search.
Be sure to also uncheck all the fields that you don't want to change (also on the right of that window), keeping only writer/composer/certification checked.
Maybe do first the test by selecting a few movies, then if it works fine do it either on all or on larger sets.
In that window there is also an option ("movies to include", on the right) where you can specify that you want to apply to all movies rather than selection.
Then when the IMDb script is selected, on the right you have some options. One is "Batch mode". It allows to suppress confirmation dialogs and use the IMDb URL from the URL field instead of doing a title search. But as I said previously, to have this working fine the movies must have the IMDb URL stored there (I assume it is the case?) so the script can fetch the right movie info without having to ask you to confirm the title search.
Be sure to also uncheck all the fields that you don't want to change (also on the right of that window), keeping only writer/composer/certification checked.
Maybe do first the test by selecting a few movies, then if it works fine do it either on all or on larger sets.
Thank you, Antoine, for helping out. The steps you suggest are exactly the steps I have been taking in trying to get the job done, but I doubt if I would have been able to communicate them as concisely and clearly as you do.
The trouble I'm running into, as you anticipate, is that I do not have the IMDb URL in most of the titles: I use All Movie Guide as my default information import site, and their title search function has changed over time and the old URLs do not work anymore.
So it seems it is going to be the long way for me, at least for now, courtesy the URL issue. Thank you once again for your help.
The trouble I'm running into, as you anticipate, is that I do not have the IMDb URL in most of the titles: I use All Movie Guide as my default information import site, and their title search function has changed over time and the old URLs do not work anymore.
So it seems it is going to be the long way for me, at least for now, courtesy the URL issue. Thank you once again for your help.
Do the AllMovieGuide script still work and does it provide info for these new fields?
If yes, maybe we could easily convert the old URLs to the new ones with a script (just post an example of the old-style URL and the corresponding new one) and do the update using AllMovieGuide.
If no, then you can run the IMDb script without activating the batch mode: you'll have to select the movie in the search result each time, but it is still rather automatic as process, as the script pass to the next movie each time by itself, and pre-fills the title.
If yes, maybe we could easily convert the old URLs to the new ones with a script (just post an example of the old-style URL and the corresponding new one) and do the update using AllMovieGuide.
If no, then you can run the IMDb script without activating the batch mode: you'll have to select the movie in the search result each time, but it is still rather automatic as process, as the script pass to the next movie each time by itself, and pre-fills the title.
Thanks, Antoine, it would be terrific if this could be worked into the All Movie Guide script. I'm using the updated version of AMG script, updated twice by Raoul and it gets the information for all the new fields after RV's update.
The new AMG URLs all work on the same lines, but the older ones have changed several times and work along three different patterns, here are examples for three titles which illustrate the three older version URLs along with the updated new ones:
Title 1: The Angels' Share:
Old URL: http://www.allrovi.com/movies/movie/the ... re-v561662
New URL: http://www.allmovie.com/movie/the-angels-share-v561662
Title 2: Angels and Demons:
Old URL: http://www.allmovie.com/work/angels-amp-demons-381322
New URL: http://www.allmovie.com/movie/angels-demons-v381322
Title: 3: Anger Management:
Old URL: http://allmovie.com/cg/avg.dll?p=avg&sql=1:276390
New URL: http://www.allmovie.com/movie/anger-management-v276390
If the writer, composer, certification fields for 2500 to 3000 titles could be imported from AMG in batches of 50 to 100 titles in one go via a script then that would be a terrific solution for the problem I'm running into. Such a script would reduce the work from two hours a day for two months to perhaps four hours flat!
Keeping my fingers crossed for some good news.
The new AMG URLs all work on the same lines, but the older ones have changed several times and work along three different patterns, here are examples for three titles which illustrate the three older version URLs along with the updated new ones:
Title 1: The Angels' Share:
Old URL: http://www.allrovi.com/movies/movie/the ... re-v561662
New URL: http://www.allmovie.com/movie/the-angels-share-v561662
Title 2: Angels and Demons:
Old URL: http://www.allmovie.com/work/angels-amp-demons-381322
New URL: http://www.allmovie.com/movie/angels-demons-v381322
Title: 3: Anger Management:
Old URL: http://allmovie.com/cg/avg.dll?p=avg&sql=1:276390
New URL: http://www.allmovie.com/movie/anger-management-v276390
If the writer, composer, certification fields for 2500 to 3000 titles could be imported from AMG in batches of 50 to 100 titles in one go via a script then that would be a terrific solution for the problem I'm running into. Such a script would reduce the work from two hours a day for two months to perhaps four hours flat!
Keeping my fingers crossed for some good news.
The two old-style "allmovie.com" URLs seem to work, so I guess they can be used as they are.
The "allrovi.com" URL however does not work.
Here is a script to apply to all the movies to change these URLs:
I updated the AllMovieGuide to version 0.7.4 to add a "BatchMode" option that you can set to 1 so it will use the URL if available, or else it will prompt for the title like the normal working mode.
The "allrovi.com" URL however does not work.
Here is a script to apply to all the movies to change these URLs:
Code: Select all
program NewScript;
var
url: string;
begin
url := GetField(fieldUrl);
url := StringReplace(url, 'allrovi.com/movies', 'allmovie.com');
SetField(fieldUrl, url);
end.
Thank you, Antoine, for the URL updating script: that works perfectly. I replaced all the old "allrovi.com" URLs with the script you have provided.
The updated All Movie Guide script v0.7.4, however, does not seem to be working as desired. If I import data for a NEW title, then the new script works perfectly, importing all the relevant/selected fields, including writer/composer/certification.
But if I am trying to UPDATE an OLD title by importing data only for writer/composer/certification then the new AMG script imports neither the writer nor the composer. The certification information does get imported successfully. I cannot figure out the reason for these irregular results.
Perhaps if you tried running the AMG script in these two ways--firstly for a new title, in which case everything works perfectly; the second time only for updating writer/composer/certification fields in an old title, in which case it doesn't work for writer/composer fields--you'll be able to figure out where the problem may be.
PS 1: I should have mentioned that I'm running the AMG script in batch mode.
PS 2: Tried running the script in non-batch mode after posting PS 1 above, but the result doesn't change: writer/composer fields do not get updated.
The updated All Movie Guide script v0.7.4, however, does not seem to be working as desired. If I import data for a NEW title, then the new script works perfectly, importing all the relevant/selected fields, including writer/composer/certification.
But if I am trying to UPDATE an OLD title by importing data only for writer/composer/certification then the new AMG script imports neither the writer nor the composer. The certification information does get imported successfully. I cannot figure out the reason for these irregular results.
Perhaps if you tried running the AMG script in these two ways--firstly for a new title, in which case everything works perfectly; the second time only for updating writer/composer/certification fields in an old title, in which case it doesn't work for writer/composer fields--you'll be able to figure out where the problem may be.
PS 1: I should have mentioned that I'm running the AMG script in batch mode.
PS 2: Tried running the script in non-batch mode after posting PS 1 above, but the result doesn't change: writer/composer fields do not get updated.
Indeed, the way the script is made it must be allowed to modify either comment or description fields.
This is because in previous versions of AMC, these fields are used to store writer etc.
So if you can update one of these two without losing anything, check one of these two.
Or else I can fix that "bug" in the script.
edit: I see other flaws similar than that in the script, I'll fix these at the same time.
This is because in previous versions of AMC, these fields are used to store writer etc.
So if you can update one of these two without losing anything, check one of these two.
Or else I can fix that "bug" in the script.
edit: I see other flaws similar than that in the script, I'll fix these at the same time.
Terrific piece of work! I've tested the script with new titles, and have also used the batch mode to update writer/composer/certification for old ones via AMG, and thus far everything seems to be working perfectly
If I notice any issue at any point in the coming days I'll post it here, but for now it is working perfectly as it should.
Thank you once again, Antoine, you've saved me hours and hours of work

Thank you once again, Antoine, you've saved me hours and hours of work

The problem with the AMG script persists: it picks up writer and composer only sporadically. I'm doing 10 titles on one go, and it picks up writer+composer data only about 2 or 3 times out of 10. The certification data comes through perfectly fine. I guess the script is still somewhat buggy, but I can't see why it should import the data occasionally while failing to do that most of the time.
Importing data for new titles still works perfectly well, the problem occurs only when updating writer+composer for old titles.
Importing data for new titles still works perfectly well, the problem occurs only when updating writer+composer for old titles.
Yes, Antoine, URL seems to be the primary issue: my catalog has AMG URLs in three formats and I ran tests using all the three formats with the following results:
TEST 1: Title: Brake. Latest AMG URL Format: http://www.allmovie.com/movie/brake-v556315
The script was run in batch mode.
All the data was filled up already, except three empty fields: writer, composer, certification. When I updated with only writer, composer, and certification selected--'allow to clear fields' also checked in 'execution options'--all three filed imported the correct data perfectly.
Checked test 1 result with another title and got exactly the same result: all the three fields imported the data perfectly.
TEST 2: Title: Bottle Rocket. Old Format 1 AMG URL: http://www.allmovie.com/work/bottle-rocket-135848
Script run in batch mode. Attempt to update selected writer, composer, and certification fields, which were the only empty ones. The imported data filled up all the three fields perfectly.
Ran 'test 2' again with two more titles and the data for all three fields--writer, composer, certification--got imported without any error.
TEST 3: Title: Bound. Old Format 2 AMG URL: http://www.allmovie.com/cg/avg.dll?p=avg&sql=1:135539
Latest AMG URL for 'Bound': http://www.allmovie.com/movie/bound-v135539/
Script run in batch mode. Attempted to update empty writer, composer, certification fields. Writer and composer remained empty, certification got filled up properly.
Ran the script once again, with the URL change option selected, no change in results, same as above. The URL did not change.
Unchecked the URL updating option and ran the script a third time. Again no change in results, the same as above: writer and composer empty, certification filled up.
Checked the result for 'test 3' with two more titles which had identical old format 2 AMG URLs and the results were exactly the same as mentioned above in the test 3 title 'Bound'.
Results seem to be self-explanatory: TEST 3 'Old Format 2 AMG URL' needs to be converted to the latest format AMG URL; perhaps you could add a line to that effect in the URL editing script you posted earlier and it should be smooth sailing thereafter. In fact, if that script is getting updated, then why not add an option for updating both the old formats to the latest one? That way the script will standardize all the URLs in the latest format through the entire catalog.
TEST 1: Title: Brake. Latest AMG URL Format: http://www.allmovie.com/movie/brake-v556315
The script was run in batch mode.
All the data was filled up already, except three empty fields: writer, composer, certification. When I updated with only writer, composer, and certification selected--'allow to clear fields' also checked in 'execution options'--all three filed imported the correct data perfectly.
Checked test 1 result with another title and got exactly the same result: all the three fields imported the data perfectly.
TEST 2: Title: Bottle Rocket. Old Format 1 AMG URL: http://www.allmovie.com/work/bottle-rocket-135848
Script run in batch mode. Attempt to update selected writer, composer, and certification fields, which were the only empty ones. The imported data filled up all the three fields perfectly.
Ran 'test 2' again with two more titles and the data for all three fields--writer, composer, certification--got imported without any error.
TEST 3: Title: Bound. Old Format 2 AMG URL: http://www.allmovie.com/cg/avg.dll?p=avg&sql=1:135539
Latest AMG URL for 'Bound': http://www.allmovie.com/movie/bound-v135539/
Script run in batch mode. Attempted to update empty writer, composer, certification fields. Writer and composer remained empty, certification got filled up properly.
Ran the script once again, with the URL change option selected, no change in results, same as above. The URL did not change.
Unchecked the URL updating option and ran the script a third time. Again no change in results, the same as above: writer and composer empty, certification filled up.
Checked the result for 'test 3' with two more titles which had identical old format 2 AMG URLs and the results were exactly the same as mentioned above in the test 3 title 'Bound'.
Results seem to be self-explanatory: TEST 3 'Old Format 2 AMG URL' needs to be converted to the latest format AMG URL; perhaps you could add a line to that effect in the URL editing script you posted earlier and it should be smooth sailing thereafter. In fact, if that script is getting updated, then why not add an option for updating both the old formats to the latest one? That way the script will standardize all the URLs in the latest format through the entire catalog.
Antoine, looking at your script I thought I'll try to do a copy-paste job for 'Old Format 2 AMG URL' and, to my complete surprise, it worked! Here is the script for updating the URL format of TEST 3 example:
I've tested the script with three titles and it imports the available data without any errors.
However, one problem remains. There is another series of URLs that I hadn't noticed before. Here are three examples:
Old Format 3 AMG URL: http://allmovie.com/cg/avg.dll?p=avg&ty ... the+Christ
Updated URL: http://www.allmovie.com/movie/the-passi ... st-v290960
Old Format 3 AMG URL: http://allmovie.com/cg/avg.dll?p=avg&ty ... ges%20Fear
Updated URL: http://www.allmovie.com/movie/the-wages-of-fear-v53139
Old Format 3 AMG URL: http://allmovie.com/cg/avg.dll?p=avg&ty ... ount+on+Me
Updated URL: http://www.allmovie.com/movie/you-can-c ... me-v187097
My rudimentary copying job did not work with this set of URLs. If preparing a script to update these URLs to the latest format is not too much of a problem then any help on this front would be much appreciated.
Code: Select all
program NewScript;
var
url: string;
begin
url := GetField(fieldUrl);
url := StringReplace(url, 'allmovie.com/cg/avg.dll?p=avg&sql=1:', 'allmovie.com/movie/v');
SetField(fieldUrl, url);
end.
However, one problem remains. There is another series of URLs that I hadn't noticed before. Here are three examples:
Old Format 3 AMG URL: http://allmovie.com/cg/avg.dll?p=avg&ty ... the+Christ
Updated URL: http://www.allmovie.com/movie/the-passi ... st-v290960
Old Format 3 AMG URL: http://allmovie.com/cg/avg.dll?p=avg&ty ... ges%20Fear
Updated URL: http://www.allmovie.com/movie/the-wages-of-fear-v53139
Old Format 3 AMG URL: http://allmovie.com/cg/avg.dll?p=avg&ty ... ount+on+Me
Updated URL: http://www.allmovie.com/movie/you-can-c ... me-v187097
My rudimentary copying job did not work with this set of URLs. If preparing a script to update these URLs to the latest format is not too much of a problem then any help on this front would be much appreciated.
Yes, I also noticed the missing number, and I suppose that was the primary reason why my copying your script didn't work in the case of this particular URL.
The variety of AMG URLs are giving more trouble than can be dealt with easily so I'm going with your earlier suggestion of importing the selected data from IMDb. Cannot work in batch mode because of URL discrepancies, but the script works very, very well and pretty much automatically except for clicking each title. Manage to do about 100 titles in 60 minutes or so, should be done in a few days.
Thanks again, Antoine.
The variety of AMG URLs are giving more trouble than can be dealt with easily so I'm going with your earlier suggestion of importing the selected data from IMDb. Cannot work in batch mode because of URL discrepancies, but the script works very, very well and pretty much automatically except for clicking each title. Manage to do about 100 titles in 60 minutes or so, should be done in a few days.
Thanks again, Antoine.