Help: a lazy bulk method to fix wrong movie length

If you need help on how to use the program
Post Reply
licht77
Posts: 2
Joined: 2009-03-27 10:35:35

Help: a lazy bulk method to fix wrong movie length

Post by licht77 »

Hi folks!

I really enjoy this movie catalog - its great!
BUT: Silly me made a mistake when entering around 1200 movies: In a first step i ran the scripts to fill in the movies data field, - and in a second step i dragged the files in to let the media info component fill in codec, filesize etc.

Now i didnt uncheck filesize, number of discs and length - so now the playing time in minutes is DOUBLED (e.g. the movie is 90 minutes - so the script filled in 90mins and media info added another 90 mins -> 180 mins total).

Is there an easy, LAZY way (without need to interact for each movie) to refill/correct/rewrite/update just the fields "length", "filesize" and "number of discs"?

Any hint is highly appreciated!
antp
Site Admin
Posts: 9651
Joined: 2002-05-30 10:13:07
Location: Brussels
Contact:

Post by antp »

Hi,
For the Length and Number of discs, you just want to divide by two then?
With such script it should work:

Code: Select all

program NewScript;
var
  n: Integer;
begin
  n := StrToInt(GetField(fieldLength), 0) div 2;
  SetField(fieldLength, IntToStr(n));
  n := StrToInt(GetField(fieldDisks), 0) div 2;
  SetField(fieldDisks, IntToStr(n));
end.
But about the file size, what has to be done?
licht77
Posts: 2
Joined: 2009-03-27 10:35:35

Post by licht77 »

WOW! You saved my lazy ass :) Thanks a lot for your fast reponse!

Your Database is GREAT - go on with your work!
Post Reply