Hi,
Steps to reproduce:
- Open the TESTCASES sample project, create a new blank app using the Wizard
- Add a DBQuery component, set the Connection property
- Open the Query Builder and add two tables: employees and current_dept_emp
- Set the join using the emp_no field
- Refresh the SQL
This is the generated sentence:
SELECT emp_no, birth_date, first_name, last_name, gender, hire_date, insdate,
upddate, emp_no, dept_no, from_date, to_date
FROM employees, current_dept_emp
WHERE current_dept_emp.emp_no=employees.emp_no
WHERE 1=1
---
WORKAROUND: If I select the Query tab and then the WHERE tab and set any filter, "WHERE 1=1" is not shown
For example, I added a gender filter:
Generated sentence:
SELECT emp_no, birth_date, first_name, last_name, gender, hire_date, insdate,
upddate, emp_no, dept_no, from_date, to_date
FROM employees, current_dept_emp
WHERE current_dept_emp.emp_no=employees.emp_no
AND (
employees.gender = :gender
)