How do I persuade DAZ Studio to rebuild the content database?

Hi.

With a lot of content from DAZ and a lot from other sites the Smart Content tab is not always the best way to browse through content, so I often use the Content Library tab and look through stuff manually.  Recently to make this easier I moved some of the files around and of course DAZ Studio now can't find some of them in Smart Content.  Is there a way to persuade the software to scan the content itself and rebuild the database?  If not, why on Earth not?

Comments

  • Fire AngelFire Angel Posts: 259

    I ought to mention that the previous version of the content directory tree is backed up, so I can revert if the database can't be rebuilt.

  • Richard HaseltineRichard Haseltine Posts: 100,948
    edited March 29

    No, because there is no way to know what product dispalced files berlong to or, in most cases, what target they should act on. That is why metdata is needed, to provide that information for the files in their default location. You can move files within Daz Studio and that will preserve the links between CMS entries and files, as long as the database survives (and possibly as long as there isn't an update). You could put the files back, or you could edit the metadata for the product they came from (but note that any product update will overwrite those edits). A safer way to move files is via links, creating a .djl file in the preferred location that points to the original: you can do that via right-click, or using http://docs.daz3d.com/doku.php/public/software/dazstudio/4/referenceguide/scripting/api_reference/samples/specific_ui/create_asset_links/start .

    Post edited by Richard Haseltine on
  • crosswindcrosswind Posts: 6,986

    If you DO want to move the product items with metadata, after moving the file locations... etc, you can always use the function "Create a Product from" in Content Library by selecting the "moved files" and paste the Product Name there. Then you'll see them correctly in Smart Content.

    Or Copy the moved items first, then locate the Product in Content Library, under Products database, then use the function Paste Reference in RMB menu. Finally "Remove Orphaned References" there.

    However, we always suggest NOT move files, especially with the Products from Daz store. You have to "correct" a lot of things. Besides, if there's a product update you're gonna install... doomed...

  • kprkpr Posts: 113
    edited March 29

    This works for things you've shifted:  https://www.daz3d.com/forums/discussion/comment/8098256/#Comment_8098256 <-- So your Content Library will work (as far as I know, for Product Updates too... I'll try to keep an eye on that in future updates)

    However, seems smart content (which I don't use) misbehaves. To fix that...

    Find an item in the Content Library Tab

    • Select it.
    • Then Right-Click it and categoriZe. (e.g. find a pair of shoes - that are for Gen8 female - and categoriZe as Wardrobe/Shoes).
    • With it still selected, right click the Content Library Tab and select "Content DB Editor"
    • Select it in the list at the top of the dialog (If it's part of an outfit)
    • Set its type (middle of dialogue box): Follower / Wardrobe / Footwear
    • Click "Accept"

    Go take a look in Smart Content (with a Gen8 female selected in your scene and "Filter by Context" selected in Smart Content tab) smiley

    Post edited by kpr on
  • crosswindcrosswind Posts: 6,986
    edited March 30

    kpr said:

    This works for things you've shifted:  https://www.daz3d.com/forums/discussion/comment/8098256/#Comment_8098256 <-- So your Content Library will work (as far as I know, for Product Updates too... I'll try to keep an eye on that in future updates)

    However, seems smart content (which I don't use) misbehaves. To fix that...

    Find an item in the Content Library Tab

    • Select it.
    • Then Right-Click it and categoriZe. (e.g. find a pair of shoes - that are for Gen8 female - and categoriZe as Wardrobe/Shoes).
    • With it still selected, right click the Content Library Tab and select "Content DB Editor"
    • Select it in the list at the top of the dialog (If it's part of an outfit)
    • Set its type (middle of dialogue box): Follower / Wardrobe / Footwear
    • Click "Accept"

    Go take a look in Smart Content (with a Gen8 female selected in your scene and "Filter by Context" selected in Smart Content tab) smiley

    This way doesn't work if one moves product items (user-acing files) to other folders from their original location, as OP mentioned.... 'cause the file link info. in cms database are broken, and files' Reference are orphaned (with exclamation marks...)

    The above is just Categorizing the items rather than rebuiding the metadata with the new file locations for the product.

    And then, a product update first uninstall the product items before reinstalling. So, in this case, the update is not able to remove the moved files from their new location 'cause DSX file never knows where they're placed by the user, so after installation, duplicate user-facing files will be seen.

     

     

    Post edited by crosswind on
  • kprkpr Posts: 113

    crosswind said:

    ...

    This way doesn't work if one moves product items (user-acing files) to other folders from their original location, as OP mentioned.... 'cause the file link info. in cms database are broken, and files' Reference are orphaned (with exclamation marks...)

    The above is just Categorizing the items rather than rebuiding the metadata with the new file locations for the product.

    And then, a product update first uninstall the product items before reinstalling. So, in this case, the update is not able to remove the moved files from their new location 'cause DSX file never knows where they're placed by the user, so after installation, duplicate user-facing files will be seen.

    For Smart Content, or Content Library?

    For Content Library I moved to an external SSD. Following the notes in the linked post my Content Library works fine. After that Smart Content seems to work if you do the DB Editor / Type thing (there'd be a lot to do, to do all content I have... but then I don't use the Smart Content tab... so haven't)

    Or do you mean something else, Crosswind?

    Product Updates - I've seen some flow through DIM, but I haven't kept an eye on what. As far as I know, all content is still working

  • crosswindcrosswind Posts: 6,986
    edited March 30

    Yep... for Smart Content.

    Categorizing always works on items as well as in Content Library but a "metadata" is not only with categories but quite a few things. By the way, the link you posted is a "page not found", I didn't know what it would refer to.

    As for product update, you can simply test it. Move some items from a product to wherever a location, then uninstall / reinstall the product in DIM... you'll find the moved files will be still there. So you have duplicated user-facing files...

    An update package just does the same thing.

    Post edited by crosswind on
  • kprkpr Posts: 113

    https://www.daz3d.com/forums/discussion/comment/8098256 <-- Try that link (its a topic on this forum) 1 up from the bottom post is a post of mine linking another post with instructions, and how to fix up a few things after following them.

    I'm a lil puzzled. I moved all my product library. Then did what's in those posts. If you move product files without the db updates it would leave those moved files if you then updated?

  • crosswindcrosswind Posts: 6,986

    kpr said:

    https://www.daz3d.com/forums/discussion/comment/8098256 <-- Try that link (its a topic on this forum) 1 up from the bottom post is a post of mine linking another post with instructions, and how to fix up a few things after following them.

    No avail... still "Page not found". 

    I'm a lil puzzled. I moved all my product library. Then did what's in those posts. If you move product files without the db updates it would leave those moved files if you then updated?

    The moved files would be still there if there's no further manipulation with them...  Smart Content and cms database are not that "smart" enough... blush

  • kprkpr Posts: 113

    crosswind said:

    kpr said:

    https://www.daz3d.com/forums/discussion/comment/8098256 <-- Try that link (its a topic on this forum) 1 up from the bottom post is a post of mine linking another post with instructions, and how to fix up a few things after following them.

    No avail... still "Page not found". 

     

    It's Daz+ will be how come.

    This is the post I reference in that post: https://www.daz3d.com/forums/discussion/627611/another-postgresql-problem

    And after doing that (content of that Daz+ post):

    Setting the path in "Preferences" seems to save the new cluster path. Setting it only in the Content Directory Manager didn't.

    Having done that ... And a "rescan", so that search functions ... All content and CMS successfully shifted to a new hard-drive.

    And having done that, new/update content is put in "new location"

    Smart Content only functions if - once you've done that - you select an item in Content Library, then right-click on "Content Library Tab" and select "Content DB Editor" and set the "Types" <-- It does then appear with "Filter by Context" ticked.

  • crosswindcrosswind Posts: 6,986

    kpr said:

    crosswind said:

    kpr said:

    https://www.daz3d.com/forums/discussion/comment/8098256 <-- Try that link (its a topic on this forum) 1 up from the bottom post is a post of mine linking another post with instructions, and how to fix up a few things after following them.

    No avail... still "Page not found". 

     

    It's Daz+ will be how come.

    This is the post I reference in that post: https://www.daz3d.com/forums/discussion/627611/another-postgresql-problem

    And after doing that (content of that Daz+ post):

    Ah ha~ that must be the reason. I used to be a Daz+ user for a long time before I turned into a "disgruntled customer", hahaha ~ But still, Scan... won't help to rebuild complete metadata for the moved files.

    Setting the path in "Preferences" seems to save the new cluster path. Setting it only in the Content Directory Manager didn't.

    Having done that ... And a "rescan", so that search functions ... All content and CMS successfully shifted to a new hard-drive.

    And having done that, new/update content is put in "new location"

    Smart Content only functions if - once you've done that - you select an item in Content Library, then right-click on "Content Library Tab" and select "Content DB Editor" and set the "Types" <-- It does then appear with "Filter by Context" ticked.

    Yep, I got this but this action is to set a Content Type but not rebuilding correct and complete metadata for the moved files. For instance, if you move a user-facing duf file from its original location to another whatever location, when DB editing on it, you'll lose all product info. from metadata.

    SNAG-2024-3-30-0028.png
    1153 x 1107 - 125K
  • Fire AngelFire Angel Posts: 259
    edited March 30

    Richard Haseltine said:

    No, because there is no way to know what product dispalced files berlong to or, in most cases, what target they should act on. That is why metdata is needed, to provide that information for the files in their default location. You can move files within Daz Studio and that will preserve the links between CMS entries and files, as long as the database survives (and possibly as long as there isn't an update). You could put the files back, or you could edit the metadata for the product they came from (but note that any product update will overwrite those edits). A safer way to move files is via links, creating a .djl file in the preferred location that points to the original: you can do that via right-click, or using http://docs.daz3d.com/doku.php/public/software/dazstudio/4/referenceguide/scripting/api_reference/samples/specific_ui/create_asset_links/start .

    If it is just the user-facing file that has moved it should contain all links relative to the base install location, so it still works, and indeed the moved files still load perfectly when double-clicked.  Studio however, was presenting me with icons for missing files in the original locations because the content database was out of sync, plus those items were not showing up in smart content as they should.  Going through the help system here eventually found me an answer (after way too many searches) and it all now works perfectly and the missing file icons have vanished.  Just right click in the content pane, select DB Maintenance and reimport all metadata.  That fixed it, the moved files still work and the missing file icons have vanished, and the smart content once again shows up in the smart content pane.

    Product updates will be another problem, but I imagine that will just be a matter of reinstalling and then moving the updated file, then DB maintenace again to ensure Studio can find it.

    Thanks to everybody who tried to help, even if I found the answer elsewhere I always appreciate it when some attempts to help me.

    Post edited by Fire Angel on
Sign In or Register to comment.