Solved

Problems with selecting all fields with a star in coldfusion MX

Posted on 2004-10-19
13
138 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
Manage your data center from practically anywhere

The KN8164V features HD resolution of 1920 x 1200, FIPS 140-2 with level 1 security standards and virtual media transmissions at twice the speed. Built for reliability, the KN series provides local console and remote over IP access, ensuring 24/7 availability to all servers.

 

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
 
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

Free Tool: Postgres Monitoring System

A PHP and Perl based system to collect and display usage statistics from PostgreSQL databases.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

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

One of the typical problems I have experienced is when you have to move a web server from one hosting site to another. You normally prepare all on the new host, transfer the site, change DNS and cross your fingers hoping all will be ok on new server…
This article provides a case study on how our local youth baseball league deployed a new website, including the platform selection, implementation and benefits to the league.
The purpose of this video is to demonstrate how to add AdSense Ads to a WordPress Website, and how to set up WordPress to automatically place Ads in Sidebars. This will be demonstrated using a Windows 8 PC. Log into your AdSense account. : Cli…
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…

820 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