Drop files here

SQL upload ( 0 ) x -

Page-related settings Click on the bar to scroll to top of page
Press Ctrl+Enter to execute query Press Enter to execute query
ascending
descending
Order:
Debug SQL
Count
Execution order
Time taken
Order by:
Group queries
Ungroup queries
Collapse Expand Show trace Hide trace Count : Time taken :
Bookmarks
Refresh
Add
No bookmarks
Add bookmark
Options
Set default





Collapse Expand Requery Edit Explain Profiling Bookmark Query failed Database : Queried time :
Browse mode
Customize browse mode.
Browse mode
Documentation Use only icons, only text or both. Restore default value
Documentation Use only icons, only text or both. Restore default value
Documentation Whether a user should be displayed a "show all (rows)" button. Restore default value
Documentation Number of rows displayed when browsing a result set. If the result set contains more rows, "Previous" and "Next" links will be shown. Restore default value
Documentation SMART - i.e. descending order for columns of type TIME, DATE, DATETIME and TIMESTAMP, ascending order otherwise. Restore default value
Documentation Highlight row pointed by the mouse cursor. Restore default value
Documentation Highlight selected rows. Restore default value
Documentation Restore default value
Documentation Restore default value
Documentation Repeat the headers every X cells, 0 deactivates this feature. Restore default value
Documentation Maximum number of characters shown in any non-numeric column on browse view. Restore default value
Documentation These are Edit, Copy and Delete links. Restore default value
Documentation Whether to show row links even in the absence of a unique key. Restore default value
Documentation Default sort order for tables with a primary key. Restore default value
Documentation When browsing tables, the sorting of each table is remembered. Restore default value
Documentation For display Options Restore default value
SELECT * FROM `invoices`
Edit inline ] [ Edit ] [ Explain SQL ] [ Create PHP code ] [ Refresh ]
Full texts id invoice_number
เลขที่ใบแจ้งหนี้/ใบเสร็จ (อาจจะสร้างทีหลัง)
opd_patient_id
FK อ้างอิง opd_patients
issue_date
วันที่ออกเอกสาร
due_date
วันที่ครบกำหนดชำระ
sub_total
ยอดรวมก่อนส่วนลด/ภาษี
discount_amount
ยอดส่วนลดรวม
tax_amount
ยอดภาษี (ถ้ามี)
grand_total
ยอดรวมสุทธิ (sub_total - discount + tax)
amount_paid
ยอดรวมที่ชำระแล้ว (ดึงจาก payments ของ treatments …
status
สถานะ Invoice
notes
หมายเหตุภายใน
terms
เงื่อนไขการชำระเงิน (แสดงให้ลูกค้า)
created_at updated_at created_by
FK อ้างอิง users
Edit Edit Copy Copy Delete Delete
DELETE FROM invoices WHERE `invoices`.`id` = 8
8 INV-202507-00008 111 2025-07-23 2025-07-23 1699.00 0.00 0.00 1699.00 1699.00 Paid 1 IVDRIP-Celeb bright8sessionFree2 (Service: IVDRI... NULL 2025-07-23 15:30:24 2025-07-23 15:30:24 1
Edit Edit Copy Copy Delete Delete
DELETE FROM invoices WHERE `invoices`.`id` = 9
9 INV-202507-00009 112 2025-07-24 2025-07-24 449.00 0.00 0.00 449.00 449.00 Paid NULL NULL 2025-07-24 13:35:40 2025-07-24 13:35:40 1
Edit Edit Copy Copy Delete Delete
DELETE FROM invoices WHERE `invoices`.`id` = 10
10 INV-202507-00010 114 2025-07-25 NULL 499.00 0.00 0.00 499.00 499.00 Paid NULL NULL 2025-07-25 16:08:31 2025-07-25 16:08:31 1
Edit Edit Copy Copy Delete Delete
DELETE FROM invoices WHERE `invoices`.`id` = 11
11 INV-202507-00011 126 2025-07-31 NULL 999.00 0.00 0.00 999.00 999.00 Paid NULL NULL 2025-07-31 20:40:43 2025-07-31 20:40:43 1
Edit Edit Copy Copy Delete Delete
DELETE FROM invoices WHERE `invoices`.`id` = 12
12 INV-202508-00012 58 2025-08-01 NULL 488.00 0.00 0.00 488.00 488.00 Paid NULL NULL 2025-08-01 19:00:52 2025-08-01 19:00:52 1
Edit Edit Copy Copy Delete Delete
DELETE FROM invoices WHERE `invoices`.`id` = 13
13 INV-202508-00013 132 2025-08-11 NULL 750.00 0.00 0.00 750.00 0.00 Unpaid NULL NULL 2025-08-11 21:50:33 2025-08-11 21:50:33 1
Edit Edit Copy Copy Delete Delete
DELETE FROM invoices WHERE `invoices`.`id` = 14
14 INV-202508-00014 151 2025-08-24 NULL 2000.00 664.00 0.00 1336.00 1000.00 Void NULL NULL 2025-08-25 00:38:44 2025-08-25 00:41:31 1
Edit Edit Copy Copy Delete Delete
DELETE FROM invoices WHERE `invoices`.`id` = 15
15 INV-202508-00015 151 2025-08-24 2025-09-17 2645.00 645.00 0.00 2000.00 1000.00 Partially Paid NULL NULL 2025-08-25 00:42:19 2025-08-25 00:42:19 1
Edit Edit Copy Copy Delete Delete
DELETE FROM invoices WHERE `invoices`.`id` = 16
16 INV-202508-00016 156 2025-08-31 NULL 868.00 0.00 0.00 868.00 868.00 Void NULL NULL 2025-08-31 22:30:59 2025-08-31 22:31:51 1
Edit Edit Copy Copy Delete Delete
DELETE FROM invoices WHERE `invoices`.`id` = 17
17 INV-202508-00017 156 2025-08-31 NULL 868.00 0.00 0.00 868.00 868.00 Paid NULL NULL 2025-08-31 22:32:17 2025-08-31 22:32:17 1
Edit Edit Copy Copy Delete Delete
DELETE FROM invoices WHERE `invoices`.`id` = 18
18 INV-202512-00018 129 2025-12-08 NULL 499.00 0.00 0.00 499.00 199.00 Partially Paid NULL NULL 2025-12-08 23:56:14 2025-12-08 23:56:14 1
Edit Edit Copy Copy Delete Delete
DELETE FROM invoices WHERE `invoices`.`id` = 19
19 INV-202512-00019 298 2025-12-11 NULL 597.00 0.00 0.00 597.00 347.00 Void NULL NULL 2025-12-11 22:10:12 2025-12-11 23:02:14 1
Edit Edit Copy Copy Delete Delete
DELETE FROM invoices WHERE `invoices`.`id` = 20
20 INV-202603-00020 415 2026-03-30 NULL 857.00 0.00 0.00 857.00 857.00 Paid NULL NULL 2026-03-30 22:03:34 2026-03-30 22:03:34 1
With selected: With selected:
Query results operations Copy to clipboard Copy to clipboard Export Export Display chart Display chart Create view Create view
Bookmark this SQL query Bookmark this SQL query