Uploaded image for project: 'Portal'
  1. Portal
  2. POR-3213

Backbone publishedIn property always empty

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Critical Critical
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: Checklistbank
    • Labels:
      None

      Description

      No current backbone usage has the name_published_in_fk key set in postgres. Likely an import or nub build bug.

        Gliffy Diagrams

          Activity

          Hide
          Markus Döring added a comment -

          Still true for january 2017 edition. Also true for the entire CoL, IPIN and many other checklists.
          But ImportIT exists to make sure namePublishedIn gets through.

          Show
          Markus Döring added a comment - Still true for january 2017 edition. Also true for the entire CoL, IPIN and many other checklists. But ImportIT exists to make sure namePublishedIn gets through.
          Hide
          Markus Döring added a comment -

          The issue lies in the implementation of NubSource and its concrete subclasses which do not provide any publishedIn data

          Show
          Markus Döring added a comment - The issue lies in the implementation of NubSource and its concrete subclasses which do not provide any publishedIn data
          Hide
          Markus Döring added a comment -

          Manually fixed the new backbone by copying over the name_published_in_fk value from the sources.
          Code fix for future builds under way.

          CREATE TABLE nubref (id int, refkey int, dataset uuid);
          INSERT INTO nubref SELECT r.nub_fk, u.name_published_in_fk, u.dataset_key FROM nub_rel r JOIN name_usage u ON u.id=r.usage_fk WHERE name_published_in_fk is not null;
          CREATE TABLE nubref2 AS SELECT DISTINCT ON (n.id) n.id, refkey FROM nubref n JOIN dataset d ON d.key=n.dataset ORDER BY n.id, d.nub_prio ASC;
          CREATE INDEX ON nubref2(id);
          UPDATE name_usage u SET name_published_in_fk=refkey FROM nubref2 n WHERE u.dataset_key=nubKey() AND u.deleted is null AND u.id=n.id;
          
          Show
          Markus Döring added a comment - Manually fixed the new backbone by copying over the name_published_in_fk value from the sources. Code fix for future builds under way. CREATE TABLE nubref (id int, refkey int, dataset uuid); INSERT INTO nubref SELECT r.nub_fk, u.name_published_in_fk, u.dataset_key FROM nub_rel r JOIN name_usage u ON u.id=r.usage_fk WHERE name_published_in_fk is not null; CREATE TABLE nubref2 AS SELECT DISTINCT ON (n.id) n.id, refkey FROM nubref n JOIN dataset d ON d.key=n.dataset ORDER BY n.id, d.nub_prio ASC; CREATE INDEX ON nubref2(id); UPDATE name_usage u SET name_published_in_fk=refkey FROM nubref2 n WHERE u.dataset_key=nubKey() AND u.deleted is null AND u.id=n.id;

            People

            • Assignee:
              Markus Döring
              Reporter:
              Markus Döring
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: