Solved

Problems with selecting all fields with a star in coldfusion MX

Posted on 2004-10-19
13
135 Views
Last Modified: 2013-12-24
I'm using SELECT * statement in  query from a mySQL database in Coldfusion MX. It all worked untill upgrading to MX. Also I'm having a problem with text fields in the MySQL database. I tried changing to blob but still the same problems. Any ideas as to what it could be?
0
Comment
Question by:rcopeman
13 Comments
 
LVL 14

Expert Comment

by:Renante Entera
ID: 12345937
Hello rcopeman!

Try to double-check the Datasource that you created on the CF Administrator.  Be sure that the account has a permission on your MySQL Database.  Verify the connection.


Goodluck!
eNTRANCE2002 :-)
0
 

Author Comment

by:rcopeman
ID: 12346017
I've tried that and it is fine.
0
 
LVL 10

Expert Comment

by:Mause
ID: 12346728
Do you get an error?
can you show us the code
0
 

Author Comment

by:rcopeman
ID: 12346755
It seems that the problem is caused by the text fields in the database. If I change the firld type to varchar(255) it all works fine. However I need a much longer text field and as soon as I use text or blob if all falls over!
0
 
LVL 10

Expert Comment

by:Mause
ID: 12346842
Do you get an error??
Or is the code working but nothing is displayed when outputting the TEXT field?
0
 

Author Comment

by:rcopeman
ID: 12346962
No. No error message but if I look at the debugging information the CFQUERY returns no records when the text fields are included. As I mentioned before if I change the text fields to varchar then it returns the correct record.

Thanks for your help. It doesnt seem to make much sence since it all worked in CF5

0
IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

 
LVL 10

Expert Comment

by:Mause
ID: 12347028
Can you post your query / code
0
 

Author Comment

by:rcopeman
ID: 12347091
     
Nothing complex:

<CFQUERY NAME="getDetails" DATASOURCE="enpod" MAXROWS="1" DBTYPE="ODBC">
      select *
      from enp_advert
      where advert_ref = #URL.id#
</CFQUERY>      

enpod is a mySQL database

Thanks
0
 
LVL 10

Expert Comment

by:Mause
ID: 12347256
Did you try the same query in mysql and did it return the record you want ?
0
 

Author Comment

by:rcopeman
ID: 12347282
Yes and it works fine!
0
 

Author Comment

by:rcopeman
ID: 12348729
OK I have found the problem. It is to do with the native drivers. I reloaded the myodbc after upgrading to MX and everything is now working fine.

Thanks for your comments.


0
 

Accepted Solution

by:
modulo earned 0 total points
ID: 12591851
PAQed with points refunded (125)

modulo
Community Support Moderator
0

Featured Post

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

This is a guide to setting up a new WHM/cPanel Server to be used for web hosting accounts. It is intended for web hosting company administrators and dedicated server owners. For under $99 per month (considering normal rate of Big Data Cetnters like …
Most ColdFusion developers get confused between the CFSet, Duplicate, and Structcopy methods of copying a Structure, especially which one to use when. This Article will explain the differences in the approaches with examples; therefore, after readin…
The purpose of this video is to demonstrate how to exclude a particular blog category from the main blog page. This is can be used when a category already has its own tab, or you simply want certain types of posts not to show up on the main blog. …
The purpose of this video is to demonstrate how to integrate Mailchimp with WordPress, by placing a Mailchimp signup form on a WordPress Page or Post. This will be demonstrated using a Windows 8 PC. Mailchimp will be used. Log into your Mailchi…

743 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

Need Help in Real-Time?

Connect with top rated Experts

11 Experts available now in Live!

Get 1:1 Help Now