If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > Data Access, Manipulation & Batch Languages > ASP > Is this possible / how can it be done?

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #16 (permalink)  
Old 09-03-09, 12:44
gvee gvee is offline
www.gvee.co.uk
 
Join Date: Jan 2007
Location: UK
Posts: 10,156
Have you included comms.asp in your test/example in post #11?
__________________
George
Twitter | Blog
Reply With Quote
  #17 (permalink)  
Old 09-07-09, 04:28
mind_grapes mind_grapes is offline
Registered User
 
Join Date: Jun 2009
Location: Midlands
Posts: 133
Hi gvee, sorry for the slow reply, something came up last week.

comms.asp is in thread #15

regards
MG
Reply With Quote
  #18 (permalink)  
Old 09-09-09, 03:52
gvee gvee is offline
www.gvee.co.uk
 
Join Date: Jan 2007
Location: UK
Posts: 10,156
Hi MG,
It may be in #15 - but was it <!--#included in the example you tested?
__________________
George
Twitter | Blog
Reply With Quote
  #19 (permalink)  
Old 09-09-09, 07:06
mind_grapes mind_grapes is offline
Registered User
 
Join Date: Jun 2009
Location: Midlands
Posts: 133
Hi gvee, thanks for the reply,

yeah it should be, its called at the top of the page in all pages.

Regards
MG
Reply With Quote
  #20 (permalink)  
Old 09-09-09, 09:02
gvee gvee is offline
www.gvee.co.uk
 
Join Date: Jan 2007
Location: UK
Posts: 10,156
What's the value of sSQL prior to executing it?
__________________
George
Twitter | Blog
Reply With Quote
  #21 (permalink)  
Old 09-10-09, 10:19
mind_grapes mind_grapes is offline
Registered User
 
Join Date: Jun 2009
Location: Midlands
Posts: 133
Hi Gvee, thanks for the reply.

I've been away from this topic in the last few days due to management wanting somethiing else done, but im now back on with this.

I have checked all files in my project, but the only time "sSQL" is declared is in the comms.asp page, like so:

Code:
<%

Dim conn, oRS, oDB, sSQL

Function OpenDB()
    conn = Application("CONN_STRING")
    Set oDB = Server.CreateObject("ADODB.Connection")
    oDB.Open(conn)
End Function


Function CloseDB()
    oDB.Close
    SET oDB = nothing
End Function


%>
And the only time the variable sSQL is set is when its in the code for example:

Code:
<%

sSQL = "exec spGetStores"
SET oRS = oDB.Execute(sSQL)
response.Write iStoreID & "-"
If Not oRS.EOF Then
    While Not oRS.EOF
        %>
This is prominent throughout the code in different pages, for instance:

Code:
Sub UpdateStoreRow()
    sSQL = "EXEC spUpdateStore " & iStoreID & "," & iStoreNumber & ",'" & sStoreName & "'"
    oDB.execute(sSQL)
End Sub

Hope this helps?

please shout if you need more.

Kind regards
MG
Reply With Quote
  #22 (permalink)  
Old 09-10-09, 11:53
gvee gvee is offline
www.gvee.co.uk
 
Join Date: Jan 2007
Location: UK
Posts: 10,156
Apologies, I meant: in your test function, right before you execute the SQL command on your open connection, what is the value of the sSQL variable?

Perform a Response.Write and see the results. I fear that your string may be empty/
__________________
George
Twitter | Blog
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On