Solved

rdoAccess

Posted on 1998-07-03
4
294 Views
Last Modified: 2008-02-01
Could any one tell me why the following code gives me this error:
"No columns were bound prior to calling SQLFetchScroll/SQLExtendedFetch"
Here is the code:
strSQL = "Select long_desc from logs where log_id = 123362"
Set .rs = .cn.OpenResultset(strSQL)
'this gives me the above error. Long_desc is a Text datatype on a remote data source
'I am trying to access the data using GetChunk, if i use "select * from logs where log_id = 123362" i do not get this error but
'long description seems to be null. i.e. GetChunk always returns no bytes.
'I am using this code to access the data.
Dim desc as string
On Error Resume Next
    Chunk = rs!long_desc.GetChunk(10)
    If Chunk > "" Then
          Desc = Desc & Chunk
          While Chunk > ""
            Chunk = rs!long_desc.GetChunk(10)
            Desc = Desc & Chunk
          Wend
    Else
        MsgBox ("field is null")
   End If
Please could anyone help?
0
Comment
Question by:Coates
  • 3
4 Comments
 

Author Comment

by:Coates
ID: 1464892
Another error occurs when i user "Select * from logs where log_id = 123362"
When i go to use GetChunk i get the following message:
"Invalid dattime format, error in parameter 23"
??????????????????????????????????
0
 

Author Comment

by:Coates
ID: 1464893
Ive just tried merely assigning the value in the text fieldto a variable using this code.
Desc = rs!long_desc
And i got the same error: "Invalid datetime format, error in parameter 23"
What does this error mean?
0
 
LVL 9

Accepted Solution

by:
cymbolic earned 50 total points
ID: 1464894
There have been some noted bugs in handling long text fields.  Generally thye workaround is to include one ordinary field/column, such as a long, etc. in your resultset.  One bug workaround is to include an additional column, and update it with its same value when updateing a text field, otherwise your text field does not get updated.  Try including another regular column in your resultset.  Memo fields are only accessed when called for later in your code, while processing your resultset.  They don't come down with the other columns in your resultset, only if/when accessed while processing the resultset.
0
 

Author Comment

by:Coates
ID: 1464895
Thanks, that worked fine.
0

Featured Post

Master Your Team's Linux and Cloud Stack

Come see why top tech companies like Mailchimp and Media Temple use Linux Academy to build their employee training programs.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

I’ve seen a number of people looking for examples of how to access web services from VB6.  I’ve been using a test harness I built in VB6 (using many resources I found online) that I use for small projects to work out how to communicate with web serv…
You can of course define an array to hold data that is of a particular type like an array of Strings to hold customer names or an array of Doubles to hold customer sales, but what do you do if you want to coordinate that data? This article describes…
Get people started with the process of using Access VBA to control Outlook using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Microsoft Outlook. Using automation, an Access applic…
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…

803 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question