I seem to have made some progress by keeping it simpler and just passing a couple of variables into the main query within the CreateMap.
________________________________ From: Stewart Wallace Sent: Sunday, 30 November 2008 20:39 To: [email protected] Subject: SparqlMotion CreateMap I am trying the get a CreateMap working at the end of an SM script and can't seem to get a result. I have tried two approachs. The first comprises: - an sml:importCurrentRDF - no problems there - an sml:SelectResource to get user input on a resource (selecting a particular subClass) which is bound to a variable 'orgtype' - no problems there - an sml:BindBySelect which runs this query - SELECT ?orgs WHERE {?orgs rdf:type ?orgtype} - it should return 19 triples - ?orgs is passed to CreateMap which has the query SELECT ?orgs ?lat ?long WHERE {?orgs geo:lat ?lat. ?orgs geo:long ?long. } The map shows but with only one node on it. The console tells me that orgs = http://www.owl-ontologies.com/unnamed0.owl#Bookshop_1_Abbeys - this is a valid value but only one value - not the 19 I want to see on the map. I wondered if I needed to iterate over the various values returned by the sml:BindBySelect - so the second approach comprises: - an sml:importCurrentRDF - no problems there - an sml:SelectResource to get user input on a resource (selecting a particular subClass) which is bound to a variable 'orgtype' - no problems there - an sml:IterateOverSelect which runs the query SELECT ?orgs WHERE {?orgs rdf:type ?orgtype} (same as above) - the sml:IterateOverSelect has a body which runs the query SELECT ?orgs ?lat ?long WHERE {?orgs geo:lat ?lat. ?orgs geo:long ?long. } - the sml:IterateOverSelect is followed by the sml:CreateMap The IterateOverSelect appears to iterate over the expected 19 instances but the map shows nothing. I don't really understand what should be in the CreateMap module - it has the slot for the selectQuery but what should go in there if it is being passed the necessary results (lat, long and all) by the IterateOverSelect? I can't find an example in the doco which actually shows the inside of a CreateMap module. Any assistance much appreciated. Stewart Wallace _______________________________________________________________________________________________ This email and any files transmitted with it are intended solely for the use of the addressee(s) and may contain information that is confidential or subject to legal privilege. If you receive this email and you are not the addressee (or responsible for delivery of the email to the addressee), please note that any copying, distribution or use of this email is prohibited and as such, please disregard the contents of the email, delete the email and notify the sender immediately. _______________________________________________________________________________________________ --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "TopBraid Composer Users" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/topbraid-composer-users?hl=en -~----------~----~----~----~------~----~------~--~---
