JAG240 / Pokemon-Map

Pokemon Map Project
2 stars 0 forks source link

Error code in oXygen #9

Open JAG240 opened 5 years ago

JAG240 commented 5 years ago

@ebeshero I was trying to troubleshoot my code for xquery in oXygen when I realized that just about anything I put in oXygen yields the error code: "Required item type of first operand of '/' is node(); supplied value has item type xs:base64Binary"

I can't seem to find anything online that is helpful to troubleshooting this. I was hoping you might have a clue. Reference to the code I was using when I found this:

let $pokemon := collection('Pokemon/')

for $p in $pokemon let $dex := $p//dexNum return $dex

ebeshero commented 5 years ago

@JAG240 I bet there's a .DS_Store file in your collection. Take a look at hidden files in your directory--this creeps in to oXygen processing over directories on your local computer. To deal with it, see https://github.com/ebeshero/DHClass-Hub/wiki/Banishing-DS_Store,-Thumbs.db,-and-other-pesky-files-we-don't-need

ebeshero commented 5 years ago

@JAG240 The other way to deal with it (that doesn't involve trying to remove the .DS_Store file) is to make your collection() function include ONLY files with a .xml extension, like we did on the XPath test. (We're doing it now in XSLT, too.) Just look at how we're modeling the collection() function on those assignments to screen out non XML files.