Despite the confusing title, I think it's pretty simple I have a database in the following format: (EXAMPLE)
---------------------------------
| X101| X102 | X103 | X104 |
---------------------------------
| COD | PROD_NAME | TYPE | INFO |
| 05 | PROD A1 | 05 | ABC |
| 019 | TAPE 01 | 05 | ABC |
| 052 | MASTER 0 | 03 | ABC |
| 111 | APPLE | 03 | ABC |
| 150 | RANDOM0 | 05 | ABC |
| 235 | ITEM661 | 03 | ABC |
| 290 | ITEM874 | 03 | ABC |
---------------------------------
I've tried in many ways, but I have not come up with a result. The database has a little more than 20 thousand products, I wanted to know how to 'select first 1' of each TYPE('group by TYPE' and show only the 'first 1' of each type)
Database is Firebird 1.5.
If You don't have any condition for "first 1" you can simply try.