I have this table:
| id | part number | serial_number | qty |
==========================================
| 1 | A | 12345 | 1 |
| 2 | A | 54321 | 1 |
| 3 | A | 67890 | 1 |
| 4 | B | | 10 |
| 5 | B | | 5 |
| 6 | C | | 6 |
| 7 | C | | 3 |
I want to group the rows like this:
| id | part number | serial_number | qty |
==========================================
| 1 | A | 12345 | 1 |
| 2 | A | 54321 | 1 |
| 3 | A | 67890 | 1 |
| 4 | B | | 10 |
| 6 | C | | 6 |
How to do this? Is this possible or not?
I want group the row by part number that doesn't have serial number. So if I have 4 rows with same part number that doesn't have serial number, it's only display 1 row.