CREATE TABLE BankStatment(
ID int, DDate Date , Desc1 varchar(30), Desc2 varchar(30) ,Debit int ,Credit int,Bal_Calc decimal
)
INSERT INTO BankStatment(ID,
DDate , Desc1 , Desc2 , Debit , Credit , Bal_Calc)
VALUES (1,'01/05/21','XYZ','123','250',NULL,'1000'),
(2,'01/05/21','ABC','100','400',NULL,'1000'),
(3,NULL,'OWE','987',NULL,NULL,NULL),
(4,'01/10/21',' XYZ ',' 777 ',' 250 ', NULL ,'1000'),
(5,NULL, 'BBB' ,'102' ,'293', NULL , NULL ),
(6,'02/10/21 ',' BOW ' , '888','100' , NULL ,'900');
What I have tried: