[XSL-LIST Mailing List Archive Home] [By Thread] [By Date]

Re: [xsl] Reflecting on: csv data to xml


Subject: Re: [xsl] Reflecting on: csv data to xml
From: Adam Retter <adam.retter@xxxxxxxxxxxxxx>
Date: Tue, 2 Jul 2013 11:57:42 +0300

On 2 July 2013 11:21, davep <davep@xxxxxxxxxxxxx> wrote:
> On 01/07/13 09:36, Adam Retter wrote:
>>
>> we have built as open source a CSV Validation tool.
>>
>> The CSV Validation tool consists of a specification for a simple text
>> grammar that describes the format of a CSV file and rules that are
>> asserted against the CSV file. It also includes an implementation for
>> the JVM (in Scala, we also provide a Java API) which takes such a
>> grammar and CSV file and  performs the validation, reporting all
>> non-validating issues or pass. The tool is available here
>> github.com/digital-preservation. It should be considered beta, i.e. we
>> are using it internally but until now it has not been publicised. In
>> addition documentation is missing but the EBNF file in the source repo
>> describes the grammar, and running the tool without arguments gives
>> you the simple command line useage. I hope documentation will follow
>> shortly, in the mean time issues etc should be aimed at the Github
>> repo.
>
>
>
> Thanks Adam, looks very useful. quick question please,
> what of disparate line lengths? Are they considered 'valid'?

I assume you mean can you have rows with different numbers of columns?
At present no, although it could be considered in future.

> The other nasty is embedded quotes, if using quotes or comma if using them?
>

We try and adhere to RFC 4180 here and there are couple of global
directives in the grammar which allow you to adjust the column
separator.


>
>
>
>
> regards
>
> --
> Dave Pawson
> XSLT XSL-FO FAQ.
> http://www.dpawson.co.uk
>



--
Adam Retter

skype: adam.retter
tweet: adamretter
http://www.adamretter.org.uk


Current Thread
Keywords