The comment in this thread about making a field mandatory yet having to rely on the application to "make it so" has me concerned. So I'd like to check if there are examples in my QAD database where a table's column is listed as N in sysprogress.syscolumns.is_nullable, but in the actual data this is violated. For this issue I don't want to rely on a copy of the data in SQL Server, so I want to run Progress code on it, MUCH preferably SQL code. Using the db copy I have in SQL Server, I can write a simple script to generate SQL statements for every possible column of the sort:
If Exists(Select * From SomeTable Where SomeColumn1 Is Null) Print 'SomeTable.SomeColumn1'
If Exists(Select * From SomeTable Where SomeColumn2 Is Null) Print 'SomeTable.SomeColumn2'
etc
But I don't see that syntax If Exists() Print 'stuff' and in my quick scan of the docs I don't see something similar. I looked at ESQL but that looks like a lot more statements (5 time the code of the IF Exists() Print example above? )
So I guess there is some really short 4GL that will do this. And I guess that will be my intro to start learning Progress 4GL. Can someone give me a few pointers to doing this simple query in 4GL code? Thanks.
maybe this will work
If Can-Find(tablename.columnname Where tablename.columnname=?) Then Display"tablename.columnname".
I'll give it a try. Hmmm, it wants a database name somewhere. I thought launching mpro with the database name and then just running one line of code like the above would work. Seems I need to do more.