Hi All,
I am relatively new to MySQL and I have come across a situation that I am not sure how to deal with it. The project is for a bookkeeping system.
I have a table called ledger_codes, and it has a PK of an integer that is auto incremented. I also have a column that records the actual ledger code, but is not auto incremented as the user sets the value.
I also have a table of transactions. One of the columns records the link to a ledger code. It is linked to the PK field in the ledger code table.
When I do a “group by” of these transactions, I need to group the records by the ledger code field, and not the PK field as is recorded in the transactions database.
I am not sure how to do this.
I can do it by the linking code easily enough, but not sure how to do it by another field. Do I do some join in the SQL statement? I am not sure how SC handles joins etc.
Thanks
Tony