{"action":"opened","issue":{"url":"https://api.github.com/repos/XLSForm/pyxform/issues/43","labels_url":"https://api.github.com/repos/XLSForm/pyxform/issues/43/labels{/name}","comments_url":"https://api.github.com/repos/XLSForm/pyxform/issues/43/comments","events_url":"https://api.github.com/repos/XLSForm/pyxform/issues/43/events","html_url":"https://github.com/XLSForm/pyxform/issues/43","id":101984290,"number":43,"title":"Add external instance when pulldata function is used","user":{"login":"MartijnR","id":627350,"avatar_url":"https://avatars.githubusercontent.com/u/627350?v=3","gravatar_id":"","url":"https://api.github.com/users/MartijnR","html_url":"https://github.com/MartijnR","followers_url":"https://api.github.com/users/MartijnR/followers","following_url":"https://api.github.com/users/MartijnR/following{/other_user}","gists_url":"https://api.github.com/users/MartijnR/gists{/gist_id}","starred_url":"https://api.github.com/users/MartijnR/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/MartijnR/subscriptions","organizations_url":"https://api.github.com/users/MartijnR/orgs","repos_url":"https://api.github.com/users/MartijnR/repos","events_url":"https://api.github.com/users/MartijnR/events{/privacy}","received_events_url":"https://api.github.com/users/MartijnR/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2015-08-19T19:55:34Z","updated_at":"2015-08-19T19:55:34Z","closed_at":null,"body":"This will create a reference to the external data in the XForm which means that strict clients (such as Enketo) will be able to use this data, e.g. by supporting the pulldata() function without data being available _magically_.\r\n\r\nSearch for pulldata expressions in the calculation column, e.g. `pulldata('hhplotdata', 'plot1size', 'hhid_key', ${hhid})`.\r\n\r\nIf found:\r\n1. check if <instance id=\"hhplotdata\"> node exists\r\n2. if not, add secondary instance to XForm output: \r\n```\r\n<instance id=\"hhplotdata\" src=\"jr://file-csv/hhplotdata.csv\" />\r\n```"}}