Solved

Are there any characters in a record set field that causes GetRows() to record the field or other fields as blanks?

Posted on 2009-07-10
3
269 Views
Last Modified: 2012-05-07
In using GetRows() in an asp/vbscript  page, including a field from a small record set which contains URLs, the GetRows() fails to get one or more of the other fields . Using the query below, the sueBlogWhatsHotParagraph field is blank
The SQL query is
"SELECT  sueBlogWhatsHotSource, sueBlogWhatsHotParagraph, sueBlogWhatsHotUrl FROM tblSueBlogWhatsHot WHERE (sueBlogID = '"&CInt(selectedBlogID)&"') AND (sueBlogWhatsHotEndDate IS NULL OR sueBlogWhatsHotEndDate >= GETDATE()) ORDER BY sueBlogWhatsHotOrder"
The four URL fields are
index.asp?leftButNo=2&selectedTopButID=6&topButNo=3&selectedBlogID=23&selectedBlogMonth=7&selectedBlogYear=2009
http://www.waitrose.com/ourcompany/leckfordestate/leckfordfarm.aspx
http://www.fifiefofum.com/newsDetails.asp?newsID=38&newsYear=2009&newsMonth=4
http://www.fifiefofum.com/galleryArtist.asp?contactNameID=660&productCategoryID=14&topButNo=1&galleryShop=2
I have experimented by including additional fields and the resulting missing fields in the array changes with the position of the URL field in the SQL query.  The URL field does appear in the array again dependent upon its position in the query.
Reloading the GetRows() array by looping through the original record set works.
0
Comment
Question by:sturgerm
  • 2
3 Comments
 
LVL 75

Expert Comment

by:Anthony Perkins
ID: 24828821
What database are you using and what are the data types for the columns selected?
0
 

Author Comment

by:sturgerm
ID: 24829456
MSQL 2008
varchar(50), varchar(max) and varchar(max)
0
 
LVL 75

Accepted Solution

by:
Anthony Perkins earned 500 total points
ID: 24830958
There used to be a problem with ADO and BLOB data types in that if you listed the BLOB fields first the rest of the columns would be Null.  It does not appear to be your case as you have listed them last.  The other possibility is that you are using an old provider that does not support the new data types.  Perhaps you can temporarily change the data types for the columns listed from varchar(MAX) to varchar(100)
0

Featured Post

Live: Real-Time Solutions, Start Here

Receive instant 1:1 support from technology experts, using our real-time conversation and whiteboard interface. Your first 5 minutes are always free.

Question has a verified solution.

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

This is pretty cool.  The purpose of this VB Script is to help you document where JAR (Java ARchive) files and specifically java class files are located so that you can address issues seen with a client or that you can speak intelligently with a dev…
Not long ago I saw a question in the VB Script forum that I thought would not take much time. You can read that question (Question ID  (http://www.experts-exchange.com/Programming/Languages/Visual_Basic/VB_Script/Q_28455246.html)28455246) Here (http…
This Micro Tutorial demonstrates using Microsoft Excel pivot tables, how to reverse engineer competitors' marketing strategies through backlinks.
A short tutorial showing how to set up an email signature in Outlook on the Web (previously known as OWA). For free email signatures designs, visit https://www.mail-signatures.com/articles/signature-templates/?sts=6651 If you want to manage em…

786 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