The second "is where" is a nested query.
If it's mySQL, a join will show rows
whether matching join rows or not, so you **might** not need a test for null. The rows without joined rows will output as NULL column values, not sure how you turn that to 0 but there's probably a way.
You also need to use group by with sum.
but they wrote only rows, where is some items ... bills where not any items not shows.
In this example, note how I've left out items 1236-1238 from items, and added multiple entries for others to test that sum is working.
create table bills (rec_id int(11) primary key auto_increment, id int(11) not null default 0);
create table items (rec_id int(11) primary key auto_increment, id int(11) not null default 0, price decimal(12,2) not null default '0.00');
insert into bills (id) values (1234);
insert into bills (id) values (1235);
insert into bills (id) values (1236);
insert into bills (id) values (1237);
insert into bills (id) values (1238);
insert into bills (id) values (1239);
insert into bills (id) values (1240);
insert into items (id,price) values (1234,'125.00');
insert into items (id,price) values (1234,'50.00');
insert into items (id,price) values (1234,'18.00');
insert into items (id,price) values (1235,'125.00');
insert into items (id,price) values (1239,'125.00');
insert into items (id,price) values (1239,'300.00');
insert into items (id,price) values (1240,'125.00');
select bills.id, sum(items.price) as sums from bills left join items on bills.id = items.id group by bills.id;
results in
id | sums
1234| 193.00
1235| 125.00
1236| NULL
1237| NULL
1238| NULL
1239| 425.00
1240| 125.00
You'd have to evaluate the null value in your programming and output a 0, or maybe there's a way to print NULL as zero . . .