ERROR 1170 (42000) : BLOB/TEXT

Author Message

rupam jaiswal

Saturday 30 September 2006 6:05:19 am

hello friends,
i am using mysql along with php. i am using xml for creating dbase. I hv create a table with some fileds among them 1 is
<field>
<name>memo_data</name>
<type>text</type>
<comment>data for ext property data_type = memo.</comment>
<add>1.1</add>
</field>
<index>
<name>index_memo_field</name>
<fieldName>memo_data</fieldName>
<fieldName>custom_field_id</fieldName>
<add>1.6</add>
</index>
the problem is when i run this,then the error appears "ERROR 1170 (42000) at line 2717: BLOB/TEXT column 'memo_data' used in key specification without a key length".
this problem is solved when i replace text with varchar and limit the length to 255 but i want it to remain text......
can any1 help me????? the meaning that i interpret from this errror msg is that limit of text should be defined but this is not possible in mysql for type text.
Regards
abcd

Kristof Coomans

Saturday 30 September 2006 6:30:09 am

Hi abcd

You need to specify the prefix length of your index, not for the database column. See http://dev.mysql.com/doc/refman/5.0/en/indexes.html

independent eZ Publish developer and service provider | http://blog.coomanskristof.be | http://ezpedia.org

Powered by eZ Publish™ CMS Open Source Web Content Management. Copyright © 1999-2014 eZ Systems AS (except where otherwise noted). All rights reserved.

eZ debug

Timing: Jan 20 2025 04:13:26
Script start
Timing: Jan 20 2025 04:13:26
Module start 'layout'
Timing: Jan 20 2025 04:13:26
Module start 'content'
Timing: Jan 20 2025 04:13:26
Module end 'content'
Timing: Jan 20 2025 04:13:26
Script end

Main resources:

Total runtime0.0179 sec
Peak memory usage2,048.0000 KB
Database Queries3

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0055 589.2734152.6406
Module start 'layout' 0.00550.0031 741.914139.4609
Module start 'content' 0.00860.0072 781.375089.3359
Module end 'content' 0.01580.0020 870.710930.3047
Script end 0.0178  901.0156 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.002514.2205140.0002
Check MTime0.00126.4898140.0001
Mysql Total
Database connection0.00105.501110.0010
Mysqli_queries0.002614.730230.0009
Looping result0.00000.084110.0000
Template Total0.00169.210.0016
Template load0.00084.707310.0008
Template processing0.00084.427110.0008
Override
Cache load0.00063.295610.0006
General
dbfile0.003016.588880.0004
String conversion0.00000.044040.0000
Note: percentages do not add up to 100% because some accumulators overlap

Templates used to render the page:

UsageRequested templateTemplateTemplate loadedEditOverride
1print_pagelayout.tpl<No override>extension/community/design/community/templates/print_pagelayout.tplEdit templateOverride template
 Number of times templates used: 1
 Number of unique templates used: 1

Time used to render debug report: 0.0001 secs