Or adapt something more universal, utilizing the Sys_Num_Cols and Sys_Table_Id from Sys_Tables, then Cursor through the Sys_Columns table where the Sys_Table_Id = Sys_Table_Id getting the Sys_Data_Type feeding into a Switch statement checking for data by column and finding data exit the cursor setting a boolean FLAG.

----- Original Message ----- From: "Lawrence Lustig" <[email protected]>
To: "RBASE-L Mailing List" <[email protected]>
Sent: Tuesday, April 07, 2009 2:46 PM
Subject: [RBASE-L] - Re: Row Check


<<
Any one got a shortcut for checking if there is data in columns in a
row?
While I can do this easily for one column I need to see if there is any
data in like 40 columns in a row. If any of these columns has data
then I need to disable the EDIT function.



The first thing this suggests is looking to see whether those 40 columns shouldn't be 40 rows related back to the main table with a key relationship. That would let you do a quick SELECT COUNT to find out whether any value has data. (I don't know whether that idea fits your data or not, just something to look at).

Failing that, the first thing I would try is a large expression in the form:

vCheckValue = (FirstTextCol + SecondTextCol + CTXT(FirstIntCol) + ThirdTextCol + CTXT(FirstRealCol))

(and so on).

If the resulting value of vCheckValue is NULL or an empty string, none of the columns had data.
--
Larry

Reply via email to