Problems connecting to several databases with TQuery

I have a SQL query that looks like this:

SELECT fi.manu_no,  fi.year_no,  fi.week_no,  fi.reel_no,  fi.order_no,
fi.order_item_no, fi.shipment_no,
fi.length_measured, fi.weight_scale, fi.reel_status, fi.reason_code,
mo.grade_code, mo_oi_ot.reels_per_package
FROM ":dbmilldata:fi", ":dbmilldata:mo", ":dbmilldata:mo_oi_ot"
(fi.reel_no=50927 AND fi.Order_no=554401 AND fi.week_no=30)
 OR (fi.reel_no=50928 AND fi.Order_no=554401 AND fi.week_no=30)

When trying to open this query with a TQuery component i get a BDE error
message "operation not appliable".  I use an INFORMIX SQL server and have
connected to this database with a TDataBase component (where the DRIVER and
DATABASENAME properties are set properly)  The strange thing is that an
almost identical query opens with no errors at all in another TQuery
component in my project.

Does anyone know the cause of this problem and the solution?