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

Using a column value as parameter to a property #113

Open lalquier opened 8 years ago

lalquier commented 8 years ago

Is it possible to map a property using a column value? As far as I can tell, Properties can only be fixed strings.

I have a use case where my data in Refine looks like: sourceURI targetURI propertyName .... (+ other columns)

I would like to generate triples along the lines of:

sourceURI mynamespace: targetURI

where comes from the value in the propertyName column.

fadmaa commented 8 years ago

you are right. it is not possible unfortunately. The best work around I could come up with if the number of unique values in the column is low, and therefore there are few unique properties, is to add an edge with each of the properties in the RDF skeleton. Then in the value use an if statement to test the value of the cell against the property name. If equals then value else null The RDF generation will ignore the edge if the value is empty/null

Not very pretty but can help in some scenarios. Regards, Fadi

On Sun, Sep 27, 2015 at 7:54 PM, Laurent Alquier notifications@github.com wrote:

Is it possible to map a property using a column value? As far as I can tell, Properties can only be fixed strings.

I have a use case where my data in Refine looks like: sourceURI targetURI propertyName .... (+ other columns)

I would like to generate triples along the lines of:

sourceURI mynamespace: targetURI

where comes from the value in the propertyName column.

— Reply to this email directly or view it on GitHub https://github.com/fadmaa/grefine-rdf-extension/issues/113.