view · edit · sidebar · attach · print · history


<< | Index | >>


  • Debug Swissmedicinfo importer



Debug ebps emediat-creation

Debug Swissmedicinfo importer

Some FI Descriptions do not have name chapter.

# expected
ch.oddb> registration("31706").fachinfo.description('de').name
-> Inderal®

# missing
ch.oddb> registration("58561").fachinfo.description('de').name
ch.oddb> registration("58561").fachinfo.description('de').name.class
-> String
ch.oddb> registration("58561").fachinfo.description('de').name.length
-> 0
ch.oddb> registration("57038").fachinfo.description('de').name
  • 58561
  • 57038
  • 57460


ebps needs :name chapter.
Debuged fiparsed. Problem is in here.

 when :swissmedicinfo
      name          ="p[text()*='#{@title}']") #=> does not match exact name (if title contains multibyte chars)
      @name         = simple_chapter(name)
      paragraph_tag = "p[@id^='section']"

Dose not match these cases as name for "®" in fiparsed.
Because title contains "®", but XML does not contain "®".
And some case (z.B. Olmetec Plus) have "®" at another position.

  • Olmetec® Plus (title)
  • Olmetec Plus® (in XML)
# title
[1] 1.9.3-p194(#<ODDB::FiParse::FachinfoHpricot>)> @title
=> "Olmetec® Plus"

# chapter
[2] 1.9.3-p194(#<ODDB::FiParse::FachinfoHpricot>)>"p[text()*='Olmetec']")
=> {elem
 <p class="s3" id="section1">
 {elem <span> {elem <span> "Olmetec Plus" </span>} </span>}
 {elem <sup class="s2"> {elem <span> "\u{ae}" </span>} </sup>}

At here, we must check exact match with name, because there are many similar names in data.
Added fallback.

ch.oddb> registration("57038").fachinfo.description('de').name
-> Olmetec Plus®

Then reparsed 40 FIs (for missing name).

Fix iksnrs match bug

If multiple iksnrs as arguments are given, TextInfo plugin could not handle each iksnrs in Regular Expression.
Because it had //o complie option.


EBook packages chapter

Ebook does not have PI Packages chapter.
Because Exporter does not export Fi Packages (currently, only PI)


Debug ebps emediat-creation

view · edit · sidebar · attach · print · history
Page last modified on May 07, 2013, at 09:22 AM