Hi,

Code below is wrong but i can't find the mistake.

Set @RecAdj:=(SELECT SUM(Paid) AS Total FROM payment WHERE PayDate = CURDATE());

if ISNULL(@RecAdj)
set @RecAdj:= 0;
end if;

Or is there any other way?

Thanks

Sorry i have forgotten to put "then".

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.