EXECUTE PROBLEM

S

Savas Ates

iam using codes which only execute first query. in loop other queries i can
write screen them but only first query making executed.. why?

for bul=0 to sayac-1

set rssil=server.CreateObject("adodb.recordset")
sil="update [sheet3$] set
urunid='',sesid='',num='',marka='',modeladi='',fiyat='',tlfiyat='',urunadi='
' where sesid='"&session.SessionID&"' and urunadi='"&delitema(bul)&"'"
baglantimiz.execute(sil)
set rssil= nothing
next
 
B

Bob Barrows

Time for some debugging. See below:
Savas said:
iam using codes which only execute first query. in loop other queries
i can write screen them but only first query making executed.. why?


Response.Write sayac & said:
for bul=0 to sayac-1

The following line is not needed
set rssil=server.CreateObject("adodb.recordset")
sil="update [sheet3$] set
urunid='',sesid='',num='',marka='',modeladi='',fiyat='',tlfiyat='',urunadi='
' where sesid='"&session.SessionID&"' and
urunadi='"&delitema(bul)&"'"

Response.Write sil & "<BR>"

This:
baglantimiz.execute(sil)
should be this:
baglantimiz.execute(sil,,129) 'adCmdText + adExecuteNoRecords

The following line is not needed
set rssil= nothing

Run the page and look at the results of the response.write statements. If
they don't show you what is wrong, show them to us.

HTH,
Bob Barrows
 
S

Savas Ates

code is


Response.Write sayac & "<BR>"
for bul=0 to sayac-1
Response.Write bul & "<BR>"

sil="update [sheet3$] set
urunid='',sesid='',num='',marka='',modeladi='',fiyat='',tlfiyat='',urunadi='
' where sesid='"&session.SessionID&"' and urunadi='"&delitema(bul)&"'"
response.write sil&"<br>"
baglantimiz.execute(sil,,129) 'adCmdText + adExecuteNoRecords


next


cant use , call a sub
error line baglantimiz.execute(sil,,129) 'adCmdText + adExecuteNoRecords
 
S

Savas Ates

output result is

4
0
update [sheet3$] set
urunid='',sesid='',num='',marka='',modeladi='',fiyat='',tlfiyat='',urunadi='
' where sesid='891158220' and urunadi='LSZAW002W0'
1
update [sheet3$] set
urunid='',sesid='',num='',marka='',modeladi='',fiyat='',tlfiyat='',urunadi='
' where sesid='891158220' and urunadi=' L300C-01AC'
2
update [sheet3$] set
urunid='',sesid='',num='',marka='',modeladi='',fiyat='',tlfiyat='',urunadi='
' where sesid='891158220' and urunadi=' PRS-201'
3
update [sheet3$] set
urunid='',sesid='',num='',marka='',modeladi='',fiyat='',tlfiyat='',urunadi='
' where sesid='891158220' and urunadi=' STR-400-1V'

code is

Response.Write sayac & "<BR>"
for bul=0 to sayac-1
Response.Write bul & "<BR>"

sil="update [sheet3$] set
urunid='',sesid='',num='',marka='',modeladi='',fiyat='',tlfiyat='',urunadi='
' where sesid='"&session.SessionID&"' and urunadi='"&delitema(bul)&"'"
response.write sil&"<br>"
baglantimiz.execute(sil)

next

still only first query executed. what is the problem...
 
R

Ray at

It says that you cannot use parentheses when calling a Sub.

baglantimiz.Execute sil,, 129

Ray at work
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,769
Messages
2,569,578
Members
45,052
Latest member
LucyCarper

Latest Threads

Top