包含多个条件的where子句的mysql查询在程序执行期间导致异常

包含多个条件的where子句的mysql查询在程序执行期间导致异常,mysql,where,clause,Mysql,Where,Clause,下面来自java的查询导致异常,表明找不到virtual_interfaces.instance_uuid列 查询字符串为: select instances.id, instances.deleted, instances.project_id, instances.hostname, instances.vm_state, instances.updated_at, instances.uuid,

下面来自java的查询导致异常,表明找不到virtual_interfaces.instance_uuid列

查询字符串为:

select instances.id, 
       instances.deleted, 
       instances.project_id, 
       instances.hostname, 
       instances.vm_state, 
       instances.updated_at, 
       instances.uuid, 
       instances.task_state, 
       virtual_interfaces.id, 
       virtual_interfaces.network_id, 
       virtual_interfaces.address, 
       virtual_interfaces.instance_uuid, 
       networks.id, 
       networks.bridge, 
       networks.cidr, 
       networks.vlan, 
       fixed_ips.address, 
       fixed_ips.network_id, 
       fixed_ips.instance_uuid 

from   instances, 
       virtual_interfaces, 
       networks, 
       fixed_ips 

where  instances.uuid=fixed_ips.instance_uuid and
       virtual_interfaces.network_id=networks.id and
       fixed_ips.instance_uuid=virtual_interfaces.instance_uuid;
如果从mysql cli执行,则相同的查询字符串也可以工作


非常感谢您的帮助。

您确定查询是相同的吗?我的意思是仔细查看?仅从查询无法真正告诉您多少。虚拟接口ddl可能会有所帮助,构建查询的java代码也会有所帮助。正如codingbiz所说,这可能是一种次要类型。