Mysql UNIQUE and .lc server scripts?

Mark Schonewille m.schonewille at
Thu May 8 19:44:06 EDT 2014

Hi John,

After executing a MySQL command with revExecuteSQL, the result contains 
either an error or an integer. If the result is an error, then you know 
that the change couldn't be made and 0 records were affected. If the 
result is an integer, then you need to check that the integer is greater 
than 0. If it isn't, something may have gone wrong and 0 records were 

Best regards,

Mark Schonewille

Economy-x-Talk Consulting and Software Engineering
KvK: 50277553

Installer Maker for LiveCode:

Buy my new book "Programming LiveCode for the Real Beginner"

LiveCode on Facebook:

On 5/9/2014 01:18, JOHN PATTEN wrote:
> Hi All,
> I’m using some .lc server scripts to add records to a database from an app. My database has one field that is UNIQUE. Is it possible to capture the mySQL message and report it back to the app when text entered for specific field is not unique?
> The database won’t create the record due to the fact that the filed is not unique, but it also does not give the user any clue of this fact.
> Thank you!
> John Patten

More information about the Use-livecode mailing list