Rico Albanese wrote: > thesql=thesql + frontpar + logtime + "," > The inclusion of this variable ^ (ie logtime) causes this script to fail. > When it is removed, it works ok. Use backquotes to turn the integer into a string, i.e., thesql=thesql + frontpar + `logtime` + ","