Yes I believe we will need a bit more details to understand your use case. You could potentially use sml:PerformUpdate to replace (DELETE/ INSERT) a triple that keeps track of the status. However that's pretty difficult. The next TBC version (scheduled for tomorrow) will have a module sml:IterateWhile that might be useful. But if you can confirm your use case we may add another type of loop similar to a for-loop in programming languages.
Holger On Dec 30, 2008, at 11:58 AM, Scott Henninger wrote: > > Jody; The "already bound" error occurs because your BindBySelect > module is trying to create the variable ?count, which was already > created in EnterLiteral (or whatever you used to get the ?count value > from the user). > > It's not clear how your script works, but you can perform your change > to ?count in the ApplyConstruct module. > > -- Scott > > On Dec 30, 12:25 pm, Jody <[email protected]> wrote: >> How can I specify, in an elegant manner, that I want to iterate >> over a >> sub-script x times. >> >> Currently I am not using the iterateOverSelect because I haven't >> wrapped my head around what variable I would bind. Instead I'm >> trying >> to use a BranchByAsk. >> >> Here is the general flow: >> Get the iteration number {?count} from the user >> :next :BranchByAsk >> :askQuery ASK{ FILTER( ?count >= 0 ) } >> :else (Do nothing :mergeModule) >> :if :ApplyConstruct (this creates individuals of a certain type >> referencing the ?count in buildURI()) >> :next :BindBySelect (decrease the ?count variable using LET) >> :next :BranchByAsk (complete loop and test again) >> >> I keep getting variable already bound errors in the :BindBySelect >> module. I've also tried replacing this with an :ApplyConstruct. >> >> Anybody have this figured out? >> >> Happy Holidays! >> >> - Jody > > --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
