Created
July 9, 2020 09:56
-
-
Save prgTW/5014b634bf18d278c0d38d12840960fb to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
SELECT 1 | |
FROM `agreement` | |
INNER JOIN `product1` ON ( | |
`agreement`.`id`=`product1`.`agreement_id` | |
AND `product1`.`status` IN ('active', 'expiring') | |
) | |
WHERE `agreement`.customer_id = :id | |
LIMIT 1 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment