Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion GroupsGeneralPHPASPPerlColdFusionFlashHTML, CSS, ScriptsBrowsers

Webmaster Forum / ASP / Database Access / March 2008



Tip: Looking for answers? Try searching our database.

text field update

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
aw - 04 Mar 2008 19:03 GMT
I am doing some scripting against a sql server database. In the course
of the scripting I update a text field of one of my tables and soon
after that run a select against that same table looking at the text
field.

For example,

update books set chapter1 = "some text about trees ..." where id = 99
.
<a few lines of work>
.
select id from books where chapter1 like '%trees%'

Is it possible that the second query is run before the update of
chapter1 from the first query is completed?
Tibor Karaszi - 04 Mar 2008 19:14 GMT
> Is it possible that the second query is run before the update of
> chapter1 from the first query is completed?

No. SQL statements are executed synchronously, seen from the client application's perspective.

Signature

Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://sqlblog.com/blogs/tibor_karaszi

>I am doing some scripting against a sql server database. In the course
> of the scripting I update a text field of one of my tables and soon
[quoted text clipped - 11 lines]
> Is it possible that the second query is run before the update of
> chapter1 from the first query is completed?
Brynn - 05 Mar 2008 01:46 GMT
> I am doing some scripting against a sql server database. In the course
> of the scripting I update a text field of one of my tables and soon
[quoted text clipped - 11 lines]
> Is it possible that the second query is run before the update of
> chapter1 from the first query is completed?

What are you experiencing?
aw - 06 Mar 2008 15:30 GMT
I have a classic asp page where I run the first update query and then
a few javascript lines later I run the select query. I am sometime not
getting that updated row in the result set for the select query.

> > I am doing some scripting against a sql server database. In the course
> > of the scripting I update atext fieldof one of my tables and soon
[quoted text clipped - 12 lines]
>
> What are you experiencing?
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2009 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.