473,386 Members | 1,819 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,386 software developers and data experts.

ADO connection.execute problem

40
Hello,

I have a problem with connection.execute statemant

Expand|Select|Wrap|Line Numbers
  1. Con.Execute("UPDATE table SET column = 'a'")
It does compile, but does not complete. It 'hangs' on this command and does nothing. No error no result.

Cheers,
sad
Mar 10 '08 #1
12 2878
debasisdas
8,127 Expert 4TB
What is the tablename and the column name.
Mar 10 '08 #2
saddist
40
table name "table" column name "column".
What's the difference?
Mar 10 '08 #3
QVeen72
1,445 Expert 1GB
Hi,

Table is a Reserved Word..
So why name a Table name as "Table"...?

Regards
Veena
Mar 10 '08 #4
debasisdas
8,127 Expert 4TB
Try avoiding the restricted key words for naming purpose.
Mar 10 '08 #5
saddist
40
Ok so table name is "ttt" and column name is "ccc". Still this does not solve the problem.
Mar 10 '08 #6
QVeen72
1,445 Expert 1GB
Hi,

This is Update Table syntax:

"UPDATE Table MyTable SET MyColName = 'a' "

Regards
Veena
Mar 10 '08 #7
debasisdas
8,127 Expert 4TB
Does your condition satisfies in the database ?
Mar 10 '08 #8
saddist
40
Hi,

This is Update Table syntax:

"UPDATE Table MyTable SET MyColName = 'a' "

Regards
Veena
ummm...no?

What do you mean by condition?
Mar 10 '08 #9
VBWheaties
145 100+
Hello,

I have a problem with connection.execute statemant

Expand|Select|Wrap|Line Numbers
  1. Con.Execute("UPDATE table SET column = 'a'")
It does compile, but does not complete. It 'hangs' on this command and does nothing. No error no result.

Cheers,
sad
It compiles because your syntax is correct. It doesnt complete because of something wrong with the data source.
I usually see hangs when I use a Sql Server that does not exist or is not online.
Mar 10 '08 #10
saddist
40
It compiles because your syntax is correct. It doesnt complete because of something wrong with the data source.
I usually see hangs when I use a Sql Server that does not exist or is not online.
Server exists and is online, becouse
Expand|Select|Wrap|Line Numbers
  1. Con.Execute("Select * from *")
works just fine.
Mar 10 '08 #11
VBWheaties
145 100+
Server exists and is online, becouse
Expand|Select|Wrap|Line Numbers
  1. Con.Execute("Select * from *")
works just fine.
I've never seen SELECT * FROM * but i'm sure its got its merits somewhere.

For your Execute, you can pass in adAsyncExecute for your Execute option parameter and it will allow you to return immediately without waiting for the Update to complete.

Expand|Select|Wrap|Line Numbers
  1.    con.Execute("Update Table Set Field = 'value'", adCmdText, adAsyncExecute)
  2.  
Mar 10 '08 #12
debasisdas
8,127 Expert 4TB
ummm...no?

What do you mean by condition?
Does your update query execute successfully at the backend outside VB ?
Mar 11 '08 #13

Sign in to post your reply or Sign up for a free account.

Similar topics

4
by: Jill Graham | last post by:
Hi, I'm using an access database and found following problem : I have a table X with 2 records : record 1 & record 2. I execute following procedure with 2 steps : 1. The procedure deletes...
6
by: Paul Robinson | last post by:
I am developing a website in ASP that connects to a Sybase database. However, when I try to open a connection to the database the page will not load. The script does not timeout, nor the...
9
by: Janick | last post by:
With DB2 7.2 we used to call methods from other SQLJ Stored Procedures, as it was not possible to call SPs via the SQL Call-statement from within SPs. So we always had a method like this: ...
4
by: Rahul Anand | last post by:
Getting SQL Exception when trying to implement Connection based Trasaction using SQL Helper class. I am using the follwing function to execute my stored procs: -=-=-=- ExecuteScalar(ByVal...
35
by: Eric Sabine | last post by:
In my Finally block, I was using cn.close (where cn is an ADO.NET connection object, SQLConnection to be exact) and then I came across the following in some microsoft code. If Not cn Is Nothing...
16
by: crbd98 | last post by:
Hello All, Some time ago, I implemented a data access layer that included a simple connectin pool. At the time, I did it all by myself: I created N connections, each connection associated with...
20
by: fniles | last post by:
I am using VB.NET 2003, SQL 2000, and SqlDataReader. As I read data from tblA, I want to populate tblB. I use SQLDataReader for both tables. I do not use thread. When I ExecuteReader on tblB, I...
1
by: Subangini | last post by:
"Hi, I am trying to migration Oracle database to mysql database using visual coding. I am having problem in the Do until loop, can u tell me what is the mistake. Oracle Database - Oracle...
6
Cintury
by: Cintury | last post by:
Hi all, I've developed a mobile application for windows mobile 5.0 that has been in use for a while (1 year and a couple of months). It was developed in visual studios 2005 with a back-end sql...
0
bartonc
by: bartonc | last post by:
This is a work in progress (current and active). There are some issues to resolve in supporting multiple connection types and I plan to add PySQLite to the mix. The this update is due to my...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.