[DDI-users] detect DDI version

Adrian Dușa dusa.adrian at unibuc.ro
Mon Jun 23 12:08:54 EDT 2014


Right... thanks Wendy!
This is exactly what I've been looking for.

Best,
Adrian


On Mon, Jun 23, 2014 at 6:58 PM, Wendy Thomas <wlt at umn.edu> wrote:

> It part of the declaration
> Note all xmlns mappings are to specific versions (in this 3.1)
>
> <DDIInstance xmlns="ddi:instance:3_1" xmlns:a="ddi:archive:3_1"
> xmlns:c="ddi:conceptualcomponent:3_1" xmlns:d="ddi:datacollection:3_1"
> xmlns:dc="http://purl.org/dc/elements/1.1/"
> xmlns:dce="ddi:dcelements:3_1" xmlns:l="ddi:logicalproduct:3_1"
>              xmlns:p="ddi:physicaldataproduct:3_1"
> xmlns:pi="ddi:physicalinstance:3_1" xmlns:r="ddi:reusable:3_1"
> xmlns:s="ddi:studyunit:3_1" xmlns:xhtml="http://www.w3.org/1999/xhtml"
> xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
>              agency="us.mpc" id="turkstat" isMaintainable="true"
> isPublished="false" version="1.0.0" versionDate="2011-04-20"
> xsi:schemaLocation="ddi:instance:3_1 instance.xsd">
>
>
> The references to the schema location should also indicate the version
> number for pre-2.5 versions of DDI-Codebook
> schemaLocation="http://www.icpsr.umich.edu/DDI
> http://www.icpsr.umich.edu/DDI/Version1-2-2.xsd"
>
> The schema naming convention changed in 2.5 to "codebook.xsd" however they
> should still be declaring a version number in the codebook element.  For
> Example: version="1.2.2"
>
> Wendy
>
>
> On Mon, Jun 23, 2014 at 10:47 AM, Adrian Dușa <dusa.adrian at unibuc.ro>
> wrote:
>
>> Hi all,
>>
>> As part of another project, I am now trying to develop a series of R
>> functions to read, update and produce XML DDI files, plus setup files
>> accompanied by ASCII data files to convert between various statistical
>> software.
>>
>> The package is soon to be submitted to CRAN, open source and GPL.
>>
>> Quick question: if a user provides a DDI XML file, is there an easy way
>> to detect it's DDI version?
>>  I could of course check for various XML entries, specific to each
>> version, but maybe there is a way to detect that in the XML header or
>> something like that.
>>
>> Thanks in advance for any hint,
>> Adrian
>>
>> --
>> Adrian Dusa
>> University of Bucharest
>> Romanian Social Data Archive
>> 1, Schitu Magureanu Bd.
>> 050025 Bucharest sector 5
>> Romania
>> Tel.:+40 21 3126618 \
>>         +40 21 3120210 / int.101
>> Fax: +40 21 3158391
>>
>> _______________________________________________
>> DDI-users mailing list
>> DDI-users at icpsr.umich.edu
>> http://lists.icpsr.umich.edu/mailman/listinfo/ddi-users
>>
>>
>
>
> --
> Wendy L. Thomas                              Phone: +1 612.624.4389
> Data Access Core Director                 Fax:   +1 612.626.8375
> Minnesota Population Center             Email: wlt at umn.edu
> University of Minnesota
> 50 Willey Hall
> 225 19th Avenue South
> Minneapolis, MN 55455
>
> _______________________________________________
> DDI-users mailing list
> DDI-users at icpsr.umich.edu
> http://lists.icpsr.umich.edu/mailman/listinfo/ddi-users
>
>


-- 
Adrian Dusa
University of Bucharest
Romanian Social Data Archive
1, Schitu Magureanu Bd.
050025 Bucharest sector 5
Romania
Tel.:+40 21 3126618 \
        +40 21 3120210 / int.101
Fax: +40 21 3158391
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.icpsr.umich.edu/pipermail/ddi-users/attachments/20140623/a97a77dc/attachment.html 


More information about the DDI-users mailing list