SQL, Code updated. Auto-Complete problem fixed thanks to joschiwald