Leading zero being stripped away??

Don, I wonder if this is what’s ultimately biting you?

<https://xojo.com/issue/32119>

Kem,

Sorry it took me a day longer than planned to try this but that software review I had with my customer yesterday turned into an all day long version of “scope creep” … everything I showed them I did resulted in a "Oh wow, if we would have known you could do that, then we would have asked you for … " (you know the routine) … good thing I get paid on cost+ basis. :slight_smile:

Anyways, tried out the prepared statement with same code I showed here earlier … it caused a hard crash of the program. Symptoms look just like Feedback Case 32119. So, I guess the answer is 32119 needs to get here quick if I want to use prepared statements for MSSQL transactions. :frowning:

… Don

Good to know, and I’m glad the source of that particular problem is now known.

So in summary, using InsertRecord with DatabaseRecord is the same as using a PreparedSQLStatement and does not require the text elements to be “cleaned”.

Also, after testing, I have found that using RecordSet.Update is also the same as using a PreparedSQLStatement unless the primary key is a string and you are trying to update it with “bad” data.

… and that,Sir, has been a most valuable revelation to me here that will favorably alter my future database coding efforts. Would have never even known it (let alone tried it) had it not been for this discussion. Many thanks for the “continuing education”, Kem!