A PHP Error was encountered

Severity: Warning

Message: mysqli::query(): (21000/1242): Subquery returns more than 1 row

Filename: mysqli/mysqli_driver.php

Line Number: 221

Backtrace:

File: /home/desa/application/models/Peraturan_model.php
Line: 23
Function: get

File: /home/desa/application/controllers/Peraturan.php
Line: 1229
Function: details_peraturan

File: /home/desa/index.php
Line: 292
Function: require_once

Database Error

A Database Error Occurred

Error Number: 1242

Subquery returns more than 1 row

SELECT *, (select attachment.file_name from attachment where attachment.id_tabel=peraturan.id_peraturan and attachment.table_name='peraturan' and attachment.keterangan='Isi Peraturan') as attachment_isi_peraturan, (select attachment.file_name from attachment where attachment.id_tabel=peraturan.id_peraturan and attachment.table_name='peraturan' and attachment.keterangan='Katalog') as attachment_katalog, (select attachment.file_name from attachment where attachment.id_tabel=peraturan.id_peraturan and attachment.table_name='peraturan' and attachment.keterangan='Abstrak') as attachment_abstrak, (select attachment.file_name from attachment where attachment.id_tabel=peraturan.id_peraturan and attachment.table_name='peraturan' and attachment.keterangan='NA') as attachment_na, (select attachment.file_name from attachment where attachment.id_tabel=peraturan.id_peraturan and attachment.table_name='peraturan' and attachment.keterangan='MOU') as attachment_mou FROM `peraturan` WHERE `peraturan`.`domain` = 'sendangsari-garung.wonosobokab.go.id' AND `peraturan`.`id_peraturan` = '1049'

Filename: models/Peraturan_model.php

Line Number: 23