`
Par2: SQL alternative to CHOOSE 2007-12-09 -- Jim Gambon > I know that I can use Choose to return different fields from a TPS file on a > condition. > > Is there a similar functionality that will work inside a Prop:SQL(Select ... > operation? Check out the use of "CASE" in a Select statement. It usually works something like this (I may not have the syntax exactly correct): SELECT CASE "fieldToTest" WHEN 'A' THEN 'Blah' WHEN 'B' THEN 'BlahBlah' WHEN 'C' THEN 'WhoZits' ELSE 'Nada' END AS "ColName" FROM "tablename" Printed November 23, 2024, 10:17 pm This article has been viewed/printed 35225 times. |