Update w/OMSQLDAM
Todd
mimm at montana.com
Wed Aug 28 00:29:52 EDT 2013
Thanks for your suggestion Keith. Can you review for me how to check the generated string? I just saw it demonstrated a few days ago, but it was in with a lot of other stuff and I didn't take sufficient notes - plus the memory isn't what it used to be! :-)
TIA
Todd
On Aug 27, 2013, at 2:40 AM, Keith Bartlett <keith at adnetltd.co.uk> wrote:
> Check the SQL produced by your $execdirect, see if it is valid. I've sometimes found an $execdirect will not work where a $prepare and $execute will, so maybe try that combination.
>
> Cheers
> Keith
>
> On 24 Aug 2013, at 03:39, Todd Mowbray wrote:
>
>> Hello All,
>>
>> I just finished a very cool and stimulating instructional/demonstration session with David Swain at the TL offices in Irvine. It has made me realize that I need to get my app to be able to be used via the web. I want to make it a two step process by providing a JS Form subset of the windows of the desktop app for the outside sales staff that will be able to have read/write access to the Omnis Datafile .df1, and then work on converting the rest of the app to SQL, etc.
>>
>> With that in mind, I have set up an SQL style JS form in the app, have created the tables and schemas, and have gotten it to log on to a OMSQLDAM session. I can do selects and inserts, and the inserts are nicely reflected in the Omnis data file as shown on the desktop windows. BUT, I am having a problem in getting an update to work. I have tried using the prebuilt $update() method (it returns flag True), I have tried creating a Statement object and using various permutations of the $execdirect method (they return flag False).
>>
>> Here are the snippets:
>>
>> Do ivClientRow.$update(iOldRow) Returns lReturnFlag (this claims success, but nothing happens to .df1)
>>
>> Then I tried:
>>
>> Do rtvSessionObj.$newstatement('CliStmnt') Returns ivStmnObj
>> Calculate ivClientRow.$statementobject as ivStmnObj
>> Do ivStmnObj.$execdirect(con('Update scClients ',rtvSessionObj.$updatenames(ivClientRow))) Returns lStatus (this shows false)
>>
>> Does anyone have any suggestions?
>>
>> TIA,
>> Todd Mowbray_____________________________________________________________
>> Manage your list subscriptions at http://lists.omnis-dev.com
>
> Keith Bartlett
> Adnet Ltd - (0)1491 642133
> www.adnetltd.co.uk
>
>
> _____________________________________________________________
> Manage your list subscriptions at http://lists.omnis-dev.com
>
More information about the omnisdev-en
mailing list