Tools – SetupBuilder

OK! So you spend all day developing, tweaking a software solution for a customer. Then you find out the actual Windows environment that they are running under… This happened to me recently..

Client wanted/needed a change… In fact, they were having problems with .TPS file on a normally reliable network. They are based about 3000 miles away!

Continue reading

The Dreaded “Record Was Changed By Another Station”

The subject error message shows up sometimes when working with Clarion and SQL based data.

When working on a recent conversion project I received the message when testing. I had moved a database from .TPS files to a MS-SQL Server database.

I had seen this message many time before, when getting started with SQL and dealing with DateTime data fields. So, I knew exactly where to look this time. Looking through the table in question, I noticed that I had no DateTime fields in the table. So something else was causing the warning “Record Was Changed By Another Station”. But, as there were no other “Stations” active, I was now in search of the source of the message.

First thing I checked was the order of the fields in my Dictionary, and the order of the fields in the database. This should not cause the error, but who knows… This all checked out OK.

Next I checked the data types were aligned and this too was all OK.

That is when I noticed that I had a STRING field in my dictionary as STRING(12) and in the database it was declared as CHAR(16). Yep, I had deliberately made it wider when I designed the new table but I had forgotten to adjust my Dictionary. Once I adjusted my dictionary to match the database, and re-compiled. all worked as it should.

But why would it report the “Record Changed By Another Station” warning, and not some more relevant message? Probably because the Clarion SQL file driver was doing its job correctly, and comparing my initially saved file buffer (with the 12 bytes I hade in my string in my dictionary). Then, just as I go to save my changed to the database, the SQL File Driver re-reads the data from the database, this time not using my data declarations, but the data as defined in the SQL table. It then does a byte-by-byte compare with the saved buffer. They do no match, so the warning message is displayed.

Bottom line: Make sure your Clarion dictionary declarations match the database fields.


SQL Programming in Clarion

I have posted several hints for working with MS-SQL2005 and get many requests for more.

If you are working with SQL-2005 Express or Standard, and have a hint you would like published, then please let me know and I will add it to the site.

The site I post to is

John Griffiths

Cool Summer

Back in Perth and summer has begun. Well, only on the calendar. It is nearly mid December and so far there has only been one day warm enough to stroll down to the beach. Maybe next weekend will be warmer, according to weather forecasters.
In the meantime, I am busy on maintenance on some systems for existing clients, and flat out on a new project (with document generation and storage involving .RTF files, Search and Replace, and generation and storage as .PDFs in an MS-SQL database). All going well so far 🙂