Hi, The reason put merge("SELECT [[tColumns]] FROM '[[tTable]]' [[myArray["test"]]] [[tSortOrder]]") into tSQL
doesn't work is the double quote around "test". Merge should work fine with arrays (I should know because bug 11274 was one of the first I ever fixed!) You can either use & and quote to build the correct string put merge("SELECT [[tColumns]] FROM '[[tTable]]' [[myArray[" & quote & test & quote & "]]] [[tSortOrder]]") into tSQL or put "test" into a variable beforehand local tTest put "test' into tTest put merge("SELECT [[tColumns]] FROM '[[tTable]]' [[myArray[tTest]]] [[tSortOrder]]") into tSQL Ali On 5 June 2015 at 08:21, Lyn Teyla <lyn.te...@gmail.com> wrote: > > function myArray pString > > return myArrayTest[pString] > > end myArray > > Small typo: > > myArrayTest[pString] > > should of course be: > > myArray[pString] > > > > _______________________________________________ > use-livecode mailing list > use-livecode@lists.runrev.com > Please visit this url to subscribe, unsubscribe and manage your > subscription preferences: > http://lists.runrev.com/mailman/listinfo/use-livecode > _______________________________________________ use-livecode mailing list use-livecode@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-livecode