|
Posted by Stefan Rybacki on 09/26/05 13:50
Bob Bedford wrote:
> "Neil Trigger" <nt018a9036@blueyonder.co.uk> a écrit dans le message de
> news: _7BZe.6310$fl6.3231@fe2.news.blueyonder.co.uk...
>
>> $query_1='INNER JOIN mod ON type.modcode = mod.modcode';
>> $query_2='INNER JOIN mak ON mod.makecode = mak.makecode';
>>
>> SELECT * FROM type ($query_1)&&($query_2)
>>
>
> I've created an other table copying the type into tbltype.
>
> syntax:
> drop table if exists tbltype;
> CREATE TABLE IF NOT EXISTS tbltype DEFAULT CHARACTER SET latin1 COLLATE
> latin1_swedish_ci(SELECT * FROM type);
>
> Then I've changed the query and now it does work always.
> What's strange anyway is that the type table is 10.1MB and the new
> tbltype is 8.9, with exactly the same number of records, same character
> set and co.
> Only thing, there is no key defined for the new table.
>
> I won't change all my php code, I would preffer to fix the problem on
> the type table instead of creating a new one and then to change my php code
>
Did you try to optimize, repair, check or analyze table type? Don't worry different sizes
of tables on same data, this could happen because of fragmentation because I guess you
already worked on the type table but didn't on the new tbltype table.
Regards
Stefan
> Bob
>
[Back to original message]
|