added more functions
updated join