Metadatamanagement: As a data user I want to see the derivedVariables

Created on 2 Jul 2020  路  6Comments  路  Source: dzhw/metadatamanagement

are they not displayed anymore?

  • adbi15: Promotionsfach (offene Angabe) (a)
  • adbi15_g3: Promotionsfach: F盲chergruppe (destatis) (c)
variablemanagement 2 1 question

Most helpful comment

@rbirkelbach Now your variables have been released: https://test.metadata.fdz.dzhw.eu/#!/de/studies/stu-gra2005?page=1&size=10&type=variables&version=2.2.0

All 6 comments

also true for PanelIdentfier馃 ?

We will show (at most two) links after the variable name which lead to the variable search datapackage details. The query string will be the identifier.

grafik

  • Releasing causes some sort of exception at the moment, hence I cannot test the public user's view.
  • derived Variables ("gra2005-ds1-aocc222j") -> I would prefer if it would look like this: derived Variables of aocc222j, but let's discuss this tomorrow in the daily standup meeting.

Test and Dev have file without contentType which causes the error on release. The following script guesses the contentTypes:

db.getCollection('fs.files').find({'metadata._contentType':{$exists:false}}).forEach(function(file) {
    if (file.filename.endsWith('.pdf')) {
        file.contentType = "application/pdf";
        file.metadata._contentType = "application/pdf";
        db.getCollection('fs.files').save(file);
    }
    if (file.filename.endsWith('.xls')) {
        file.contentType = "application/vnd.ms-excel";
        file.metadata._contentType = "application/vnd.ms-excel";
        db.getCollection('fs.files').save(file);
    }
    if (file.filename.endsWith('.xlsx')) {
        file.contentType = "application/x-tika-msoffice";
        file.metadata._contentType = "application/x-tika-msoffice";
        db.getCollection('fs.files').save(file);
    }
    if (file.filename.endsWith('.png')) {
        file.contentType = "image/png";
        file.metadata._contentType = "image/png";
        db.getCollection('fs.files').save(file);
    }
    if (file.filename.endsWith('.svg')) {
        file.contentType = "image/svg+xml";
        file.metadata._contentType = "image/svg+xml";
        db.getCollection('fs.files').save(file);
    }
});

db.getCollection('fs.files').find({'metadata._contentType': null}).forEach(function(file) {
    if (file.filename.endsWith('.pdf')) {
        file.contentType = "application/pdf";
        file.metadata._contentType = "application/pdf";
        db.getCollection('fs.files').save(file);
    }
    if (file.filename.endsWith('.xls')) {
        file.contentType = "application/vnd.ms-excel";
        file.metadata._contentType = "application/vnd.ms-excel";
        db.getCollection('fs.files').save(file);
    }
    if (file.filename.endsWith('.xlsx')) {
        file.contentType = "application/x-tika-msoffice";
        file.metadata._contentType = "application/x-tika-msoffice";
        db.getCollection('fs.files').save(file);
    }
    if (file.filename.endsWith('.png')) {
        file.contentType = "image/png";
        file.metadata._contentType = "image/png";
        db.getCollection('fs.files').save(file);
    }
    if (file.filename.endsWith('.svg')) {
        file.contentType = "image/svg+xml";
        file.metadata._contentType = "image/svg+xml";
        db.getCollection('fs.files').save(file);
    }
});

@rbirkelbach Now your variables have been released: https://test.metadata.fdz.dzhw.eu/#!/de/studies/stu-gra2005?page=1&size=10&type=variables&version=2.2.0

Was this page helpful?
0 / 5 - 0 ratings