![]() | ![]() Products ![]() ![]() ![]() ![]() |
Home » Technical Support » ElevateDB Technical Support » Support Forums » ElevateDB SQL » View Thread |
Messages 1 to 3 of 3 total |
![]() |
Fri, Oct 2 2015 6:21 AM | Permanent Link |
Adam Brett Orixa Systems | I have a record which has a group of child records.
The child records contain a boolean field. For the master record, if ANY of the child record-boolean fields is true I need to take an action. At present the best SQL I can write is: IF('TRUE' IN (REPLACE('FALSE,' WITH '' IN LIST(CAST(SD.ActionRequired as VARCHAR)))) then 8 else 7) as StateID, This seems heavy-handed, as I would expect there to be some sort of "boolean summing" function available somewhere but I can't see any. |
Fri, Oct 2 2015 10:08 AM | Permanent Link |
Tim Young [Elevate Software] Elevate Software, Inc. ![]() | Adam,
<< At present the best SQL I can write is: >> Is that in the SELECT list, or in the WHERE clause ? << This seems heavy-handed, as I would expect there to be some sort of "boolean summing" function available somewhere but I can't see any. >> Are you looking for the count of children with a True Boolean column value, or what ? Tim Young Elevate Software www.elevatesoft.com |
Fri, Oct 2 2015 10:09 AM | Permanent Link |
Tim Young [Elevate Software] Elevate Software, Inc. ![]() | Adam,
After thinking about it, I think I know what you're trying to do. However, if you send your existing SQL (and/or table structures), I can tell you exactly what the SQL should be. Tim Young Elevate Software www.elevatesoft.com |
This web page was last updated on Wednesday, July 2, 2025 at 06:46 PM | Privacy Policy![]() © 2025 Elevate Software, Inc. All Rights Reserved Questions or comments ? ![]() |