SDK Utility Functions

I'm trying to update a single record using an SDK Utility function using vb.net.  I seen the example Sage provided that can update ALL field records.  Here's syntax:

Util.RunNonQuery("Update titluli SET sDesc = something")

This will update all records for field sDesc in table titluli.

I only want to update select records.  I thought this may work

Util.RunNonQuery("Update titluli SET sDesc = something" Where lITRecid = "something")

I do NOT get a syntax error, but nothing gets updated.  Do you know why?  Is there a way to update a specific record for a specific field using the SDK utility functions?

Thanks.

Parents
  • 0

    JimatRogers said:
    Util.RunNonQuery("Update titluli SET sDesc = something" Where lITRecid = "something")

    I don't use the SDK but your SQL statement is not formatted correctly.

    Richard S. Ridings said:
    UPDATE titluli SET sDesc = 'something' WHERE lITRecid = 555

    should be the statement you want if you wish the word something to show up on every line of invoice with lItRecId # 555.

  • 0 in reply to Richard S. Ridings
    RIchard,

    I appreciate your reply, and yes, you are correct in your formatting. I actually should have typed it out as you did. My problem is the Where clause is essentially being ignored. I was wondering if anyone has used the Util.RunNonQuery with a Where clause and got it to work using the SDK utility? Again, thanks for replying. It's appreciated.
  • 0 in reply to JimatRogers
    As far as I know, you can't do anything really useful without a WHERE statement so I would expect it to be allowed. Are you sure it's not just your syntax? You did put the "something" after lITRecId in double quotes and normally you don't use them for integers only strings.
Reply Children
No Data