Quantcast
Channel: Classic ASP
Viewing all articles
Browse latest Browse all 488

2 db connection on 1 asp page

$
0
0

Hi all,

Now I have problem when make a asp page.

I use 2 db connection connect to 2 db differrent

And then have some query execute on db1, some query execute on db2.

Begintrans

If true -> Commit

else -> Rollback

But this case, db1/db2  still insert records. 

Thanks for all!

---------------------------------------

db1.execute

db2.execute

if use - stock <=0 then

message -> out of stock

history.back()

response.end

end if

if err.count <> 0 

db1.commitTrans

db2.commitTrans

else

db1.RollbackTrans

db2.RollbackTrans

enf if


Viewing all articles
Browse latest Browse all 488

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>