[ psqlodbc-Bugs-1000648 ] Visual Studio 2005 DataSet Designer "Add Query..." wizard fails with a syntax error if SELECT query contains a WHERE clause
От | |
---|---|
Тема | [ psqlodbc-Bugs-1000648 ] Visual Studio 2005 DataSet Designer "Add Query..." wizard fails with a syntax error if SELECT query contains a WHERE clause |
Дата | |
Msg-id | 20060519052301.9735586C4DC@pgfoundry.org обсуждение исходный текст |
Список | pgsql-odbc |
Bugs item #1000648, was opened at 2006-05-19 05:23 You can respond by visiting: http://pgfoundry.org/tracker/?func=detail&atid=538&aid=1000648&group_id=1000125 Category: None Group: None Status: Open Resolution: None Priority: 3 Submitted By: Patrick Donelan (patspam) Assigned to: Nobody (None) Summary: Visual Studio 2005 DataSet Designer "Add Query..." wizard fails with a syntax error if SELECT query contains a WHEREclause Initial Comment: Hi, I'm using the latest version of the drivers: 8.02.00.02 and PostgreSQL 8.1 on Windows XP Pro. When adding simple queries to TableAdapters in Visual Studio 2005 using the DataSet Designer, a simple WHERE clause causesthe Add Query wizard to fail with a syntax error, even though the query executes perfectly if you test it during an intermediate Wizardstep. Simple Steps To Reproduce ------------------------- 1. Open an existing DataSet in the DataSet Designer (or create a new one) 2. Add a TableAdapter, with a simple query (in my case "SELECT * FROM agent") 3. Add a Query to the TableAdapter: Right-click on TableAdapter > Add Query.. > Use SQL statements > SELECT which returns rows 4. Type in a simple SELECT using a single WHERE clause (in my case "SELECT * from agent WHERE (agent_id = ?)") 5. Click Query Builder.. > Execute Query (prompts for Query Parameter and executes perfectly) 6. Click OK > Next > Next (leave "Fill a DataTable" and "Return a DataTable" checked) > Next At this point, even though the query executed perfectly in the Query Builder, you get an error: "The wizard detected the following problems when configuring TableAdapter query "FillBy": Details: Generated SELECT statement. ERROR [42601] ERROR: syntax error at or near ")"; Error while executing the query" I have found a partial workaround: 1. Use the Wizard to create the query (with WHERE clause omitted) 2. Right-click on the new query and select properties 3. Modify the query in the CommandText property window Logs attached. Regards, Patrick ---------------------------------------------------------------------- You can respond by visiting: http://pgfoundry.org/tracker/?func=detail&atid=538&aid=1000648&group_id=1000125
В списке pgsql-odbc по дате отправления: