Source language: Translate to:

Error Message when Update a field

Questions about our Advanced Database plug-in

Moderator: Neosoft Support

Error Message when Update a field

Postby carlos torres » Thu Jul 19, 2007 7:28 am

Hi
When i try to update an specific field of a table a get a warning message that says "Command text does not return a result set".

I test both ways as SQL string and as single statement... in both cases i got the same message.

Code: Select all
.../// case 1 w/ string
InputBox "Mark?" "Write a value (0-5)" "[xMark]"
SetVar "[strSQL]" "UPDATE Student SET Mark5=[xMark]"
dbpExecSQL "DbLst" "[strSQL]" "Student"

.../// case 2 directly single statement
dbpExecSQL "DbLst" "UPDATE Student SET Mark5=3.0" "Student"


What happen?
What I'm doing wrong?

I will appreciate your help, Regards

carlost
User avatar
carlos torres
 
Posts: 289
Joined: Mon May 02, 2005 8:14 am
Location: Pamplona, Colombia

Postby Neosoft Support » Thu Jul 19, 2007 10:25 am

For SQL commands that do not return results such as "UPDATE", you must leave the last parameter of dbpExecSQL empty. For example:

dbpExecSQL "DbLst" "[strSQL]" ""
NeoSoft Support
Neosoft Support
NeoSoft Team
 
Posts: 5603
Joined: Thu Mar 31, 2005 10:48 pm
Location: Oregon, USA

Postby carlos torres » Thu Jul 19, 2007 5:34 pm

Hi NeoSoft

I was thinking that the third parameter of the statement, was the table where the recordset is returned.

dbpExecSQL "DbLst" "[strSQL]" ""

The help file says it is optional.... I leave it empty and it works

thanks

regards

carlost
User avatar
carlos torres
 
Posts: 289
Joined: Mon May 02, 2005 8:14 am
Location: Pamplona, Colombia


Return to NeoBookDBPro

Who is online

Users browsing this forum: No registered users and 1 guest

cron