i have 3 table to sum the spent, but it is not working properly, how to fix it here i have link to sql fiddle link