像上图这样复杂的多条件数据库查询,sql语句怎么写额?有经验的老师给个方案呗。
字符串拼接sql := ' select * from table where 1 = 1 ';if ... then sql := sql + ' and 销售时间 = xxxx ';if ... then sql := sql + ' and 客户名称 = xxxx ';...