distal-attribute
distal-attribute
distal-attribute
distal-attribute

(BYTES) value in resultset

User, date Message
Written by siMKin
6 years ago
Category: General
104 posts since Sun, 01 Apr 07
When i execute the following queries in the Query tab:

SELECT 2008, CONCAT('0', '8') AS WeekNR;
SELECT 2008, CONCAT('0', 8) AS WeekNR;



It returns:
------------------------
2008 WeekNR
2008 08
------------------------

in both cases.

When i preform the following query:

CREATE TEMPORARY TABLE testing SELECT 2008, CONCAT('0', '8') AS WeekNR;
SELECT * FROM testing;



Again, i have the same result.

However, if i perform this query:

CREATE TEMPORARY TABLE testing2 SELECT 2008, CONCAT('0', 8) AS WeekNR;
SELECT * FROM testing2;



I get this result:
------------------------
2008 WeekNR
2008 (BYTES)
------------------------

I wonder two things:

- When i execute these queries under the mysql-prompt i don't see any difference. How comes Heidi put (BYTES) in that field and how do i retrieve the actual value from it (in Heidi).
- There is a subtle difference between the way the temporary tables are made and i'm sure it's that difference that is creating the problem. But i'm also very interested in what the difference on the level of mysql is... how the data is actually stored in the temporary table. More so, because in earlier versions of mysql there was a bug that wouldnt display the data correctly as well. Apparently the bug has been fixed, but there is still a difference.[/list]
 

Please login to leave a reply, or register at first.