serverup

Q: making lookups permanent

Is there a way to make a lookup entry permanent. For example, if I use a lookup for editor name field, when I change the lookup when an editor leaves, it changes all of their assets name field to (None). What I would like is that the data to "stick".

Final Cut Server, Mac OS X (10.6.7)

Posted on May 1, 2011 8:46 AM

Close

Q: making lookups permanent

  • All replies
  • Helpful answers

  • by Alejandro Grigera,

    Alejandro Grigera Alejandro Grigera May 3, 2011 9:10 AM in response to serverup
    Level 1 (55 points)
    May 3, 2011 9:10 AM in response to serverup

    I'm almost sure you can't. I can tell you what I do in a case similar to yours. I use another string field wich is hidden (different metadata group) and I have a subscription that copies the data from the lookup field everytime it changes to the string hidden one. For the user is the lookup with the available options today but for admin or any other things you want to do with the list in the hidden field you have the correct names that "stick" for as long as you want.

     

    Hope this help

  • by Michael Guncheon,

    Michael Guncheon Michael Guncheon May 4, 2011 8:27 AM in response to Alejandro Grigera
    Level 1 (35 points)
    May 4, 2011 8:27 AM in response to Alejandro Grigera

    That sounds like a plan.

     

    How are you doing your subscription/response to copy from one field to another?

  • by Alejandro Grigera,

    Alejandro Grigera Alejandro Grigera May 5, 2011 9:14 AM in response to Michael Guncheon
    Level 1 (55 points)
    May 5, 2011 9:14 AM in response to Michael Guncheon

    Sorry I forgot you can't do that from FCS, what I use is the simplest script to change that.

    you have to set a suscription that runs everytime the lookup changes and trigger a "Run an External Script" response. Make sure you send the asset id and the lookup value to the script.

    #!/bin/bash

    ASSET_ID=$1

    PROGRAM=$2

    cd "/Library/Application Support/Final Cut Server/Final Cut Server.bundle/Contents/MacOS"

    sudo ./fcsvr_client setmd /asset/$ASSET_ID PA_MD_CUST_PROGRAM_HIDDEN="$PROGRAM"

    exit 0

     

    Hope this help

  • by Michael Guncheon,

    Michael Guncheon Michael Guncheon May 5, 2011 1:16 PM in response to Alejandro Grigera
    Level 1 (35 points)
    May 5, 2011 1:16 PM in response to Alejandro Grigera

    I will give that a try, thanks.

     

    One question about the trigger though...

     

    Since it will trigger with every change in the lookup, is it correct to assume that if you delete a value in the lookup, it won't trigger when you look at an asset (and the lookup value is now 'null'?

  • by Alejandro Grigera,

    Alejandro Grigera Alejandro Grigera May 5, 2011 1:35 PM in response to Michael Guncheon
    Level 1 (55 points)
    May 5, 2011 1:35 PM in response to Michael Guncheon

    To be honest with you, that was a very good question. Just tested in a FCS 1.5 that I have and the hidden field keeps it's value when the lookup field changed to None after I erased the value.

    If you don't want any problem in the future and want to be completely sure nothing will change you can put the setmd line inside an IF that checks if the program variable is not empty.

     

    Best regards

  • by serverup,

    serverup serverup May 5, 2011 8:38 PM in response to Alejandro Grigera
    Level 1 (0 points)
    May 5, 2011 8:38 PM in response to Alejandro Grigera

    Thanks to both of you, gives me so good ideas.