ExecuteSQLit sql=
create temporary table tmp1 as select TabID from Tabs where ParentId='$tabid,' and ProjectID in ('0','0') and (AuthorizedRoles='' or instr(AuthorizedRoles, 'X;')>0) and isVisible=1 and isDeleted=0 and Title<>""

Truncated incorrect DECIMAL value: '$tabid,'