fadmaa / grefine-rdf-extension

An extension to Google Refine that enables graphical mapping of Google Refine project data to an RDF skeleton and then exporting it in RDF format
http://refine.deri.ie
Other
94 stars 55 forks source link

High numbers as URIs #9

Closed thosch closed 13 years ago

thosch commented 13 years ago

I have a column with IDs like 10102010 that I want to use to create URIs.

But with integers this high the RDF output is e.g. http://test.org/1.010201E7

fadmaa commented 13 years ago

you need to convert the integer to string. one way to do so is: value.toString() this needs to be entered for the URI expression. if this is not clear see a more detailed description below:

In the node configuration dialog (the one that appears after clicking on a node in the graph template) you can use the preview/edit link to enter a custom expression. value.toString() needs to be used there as the value for the expression input.

the dialog is shown in this image http://lab.linkeddata.deri.ie/2010/grefine-rdf-extension/imgs/preview_uri_example.png

hope that helps!

thosch commented 13 years ago

Hello Fadi,

in fact, the value.toString() seems to be the problem, not the solution. Here is what is on my screen:

Expression value.toString()

row | value | value.toString()

  1. | 10101010 | 1.010101E7
fadmaa commented 13 years ago

hello, looks like this is similar to an issue reported on Google Refine: http://code.google.com/p/google-refine/issues/detail?id=189

The solution suggested there id to turn "auto-detect value types" off when creating the project. Some people report that this is not always working properly.

let me know if that works for you

Regards, Fadi

thosch commented 13 years ago

Hi, without "auto-detect values" Refine appends a ".0" to each number. But I solved my problem with the scientific notation with a search/replace workaround in a text edtior. Cheers, Thomas