<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def get_splits_query(self):
 """ Returns the query for all splits for this security """

        query = (
            self.book.session.query(Split)
            .join(Account)
            .filter(Account.type != AccountType.trading.value)
            .filter(Account.commodity_guid == self.security.guid)
        )
        return query