AnsweredAssumed Answered

ExecuteSQL  just not working

Question asked by tobe32 on Feb 1, 2019
Latest reply on Feb 6, 2019 by tobe32


i am working on a database for an orgnization that people sponsor kids as all they have ever used to track kids, sponors, and donations is excel and obviously its not working well, but i am stuck on getting my ExecuteSQL command to work.


What i want to do is to look into the finances database to find our how much a sponsor has given toward thier sponsor.


The donations are stored in the database Finances_2, and the donors are stored in Donors

if the reason  the donation entered is = to the variable Current_Donor_Year & the donor being displayed matches i want the sum of the donations.


This is my command at the momnet


Let ( [ query    = " select SUM (Amount_Donated) from Finances_2

WHERE Finances_2::Reason=Current_Donor_Year


WHERE Finances_2::Donor_First=Donor_First_Name


" ] ;

ExecuteSQL ( query ; "" ; "" ) )


i hope that explains enough of what i need to do, thanks