I have seen three issues whilst exploring DataSources in SNAPSHOT_v10.1d_2014-11-17/Pro Development Only
**First issue**
1. Open Visual Builder
2. Go to the DataSources pane
3. Click Add...
4. Click New DataSource...
5. Choose 'Existing SQL Table or View' under 'SQLDataSource'
6. Click 'Next >'
In the JS console you will see: "Uncaught TypeError: undefined is not a function"
In the SmartClient console the following error:
**Second issue**
In the adminConsole I successfully added a postgresql database after adding the postgres driver. I can then select the DB on the 'Database Configuration' tab and click 'Browse' to go to the 'SQL Browser' tab.
If I then select a table from the 'Tables & Views' section, it shows the contents of the table as expected.
However, if I click the 'Next >' button below the 'Tables & Views' section, I get the following JS error:
Uncaught TypeError: Cannot set property 'defaults' of undefined
And in the console:
The entire 'SQL Browser' tab pane then goes blank.
**Third problem**
Some of my postgres views contain colons in their names. This is valid postgres, but you have to escape the names with double quotes in the SQL queries:
It seems that the browser does not escape the table names and therefore won't let you view those tables/views with the error:
All in all, with these problems, I'm struggling to be able to auto generate a datasource from my postgres views or tables.
If I try to hit the DataSource Generator from the Tools window in http://localhost:8080/docs/resources/explorer.html in attempts to open http://localhost:8080/tools/dsGenerator.jsp which is a 404.
Should I expect to be able to generate datasources from postgres tables? I know batch generation is a feature of the enterprise licence, but I'd was expecting single generation to be part of the Pro licence.
Many thanks
**First issue**
1. Open Visual Builder
2. Go to the DataSources pane
3. Click Add...
4. Click New DataSource...
5. Choose 'Existing SQL Table or View' under 'SQLDataSource'
6. Click 'Next >'
In the JS console you will see: "Uncaught TypeError: undefined is not a function"
In the SmartClient console the following error:
Code:
10:50:56.670:MUP9:WARN:Log:TypeError: undefined is not a function Stack from error.stack: DSWizard.nextPage(<no args: exited>) @ ISC_Tools.js:85:169 [o]Button.eval(<no args: exited>) @ [no file]:3:21 Button.handleActivate(<no args: exited>) @ ISC_Foundation.js:233:108 Button.handleClick(<no args: exited>) @ ISC_Foundation.js:234:13 EventHandler._bubbleEvent(<no args: exited>) @ ISC_Core.js:1587:89 EventHandler._handleClick(<no args: exited>) @ ISC_Core.js:1448:50 EventHandler.__handleMouseUp(<no args: exited>) @ ISC_Core.js:1433:11 EventHandler._handleMouseUp(<no args: exited>) @ ISC_Core.js:1424:41 EventHandler._dispatch(_1=>[c]EventHandler.handleMouseUp(), _2=>[object MouseEvent]) @ ISC_Core.js:1662:108 HTMLDocument.eval(event=>[object MouseEvent]) @ [no file]:3:123
In the adminConsole I successfully added a postgresql database after adding the postgres driver. I can then select the DB on the 'Database Configuration' tab and click 'Browse' to go to the 'SQL Browser' tab.
If I then select a table from the 'Tables & Views' section, it shows the contents of the table as expected.
However, if I click the 'Next >' button below the 'Tables & Views' section, I get the following JS error:
Uncaught TypeError: Cannot set property 'defaults' of undefined
And in the console:
Code:
10:56:44.426:MUP2:WARN:Log:TypeError: Cannot set property 'defaults' of undefined Stack from error.stack: [o]Button.click(<no args: exited>) @ ISC_Tools.js:131:701 Button.handleActivate(<no args: exited>) @ ISC_Foundation.js:233:108 Button.handleClick(<no args: exited>) @ ISC_Foundation.js:234:13 EventHandler._bubbleEvent(<no args: exited>) @ ISC_Core.js:1587:89 EventHandler._handleClick(<no args: exited>) @ ISC_Core.js:1448:50 EventHandler.__handleMouseUp(<no args: exited>) @ ISC_Core.js:1433:11 EventHandler._handleMouseUp(<no args: exited>) @ ISC_Core.js:1424:41 EventHandler._dispatch(_1=>[c]EventHandler.handleMouseUp(), _2=>[object MouseEvent]) @ ISC_Core.js:1662:108 HTMLDocument.eval(event=>[object MouseEvent]) @ [no file]:3:123
**Third problem**
Some of my postgres views contain colons in their names. This is valid postgres, but you have to escape the names with double quotes in the SQL queries:
Code:
SELECT * FROM "my:table";
Code:
10:59:24.827:IBLR8[E0]:WARN:RPCManager:org.postgresql.util.PSQLException: ERROR: syntax error at or near ":" Position: 34 at org.postgresql.core.v3.QueryExecutorImpl.receiveErrorResponse(QueryExecutorImpl.java:2198) at org.postgresql.core.v3.QueryExecutorImpl.processResults(QueryExecutorImpl.java:1927) at org.postgresql.core.v3.QueryExecutorImpl.execute(QueryExecutorImpl.java:255) at org.postgresql.jdbc2.AbstractJdbc2Statement.execute(AbstractJdbc2Statement.java:561) at org.postgresql.jdbc2.AbstractJdbc2Statement.executeWithFlags(AbstractJdbc2Statement.java:405) at org.postgresql.jdbc2.AbstractJdbc2Statement.executeQuery(AbstractJdbc2Statement.java:285) at org.apache.commons.dbcp.DelegatingStatement.executeQuery(DelegatingStatement.java:208) at com.isomorphic.sql.SQLDriver.getTransformedResults(SQLDriver.java:717) at com.isomorphic.sql.SQLDriver.getTransformedResults(SQLDriver.java:565) at com.isomorphic.sql.SQLDriver.getTransformedResults(SQLDriver.java:558) at com.isomorphic.sql.SQLDriver.getScalarResult(SQLDriver.java:751) at com.isomorphic.sql.SQLDriver.executeScalar(SQLDriver.java:1046) at com.isomorphic.sql.SQLDataSource.runRowCountQuery(SQLDataSource.java:3016) at com.isomorphic.sql.SQLDataSource.executeWindowedSelect(SQLDataSource.java:2413) at com.isomorphic.sql.SQLDataSource.SQLExecute(SQLDataSource.java:1955) at com.isomorphic.sql.SQLDataSource.processRequest(SQLDataSource.java:448) at com.isomorphic.sql.SQLDataSource.executeFetch(SQLDataSource.java:393) at com.isomorphic.datasource.DataSource.execute(DataSource.java:2078) at com.isomorphic.application.AppBase.executeDefaultDSOperation(AppBase.java:724) at com.isomorphic.application.AppBase.executeAppOperation(AppBase.java:650) at com.isomorphic.application.AppBase.execute(AppBase.java:491) at com.isomorphic.datasource.DSRequest.execute(DSRequest.java:2578) at org.apache.jsp.tools.adminConsoleOperations_jsp._jspService(adminConsoleOperations_jsp.java:149) at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70) at javax.servlet.http.HttpServlet.service(HttpServlet.java:723) at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:388) at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:313) at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:260) at javax.servlet.http.HttpServlet.service(HttpServlet.java:723) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at com.isomorphic.js.JSSyntaxScannerFilter._doFilter(JSSyntaxScannerFilter.java:252) at com.isomorphic.servlet.BaseFilter.doFilter(BaseFilter.java:83) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:103) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109) at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:293) at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:861) at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:606) at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:489) at java.lang.Thread.run(Thread.java:744) undefined - response: {operationId: "cache:devices_sortorders_dbBrowser_fetch", clientContext: Obj, internalClientContext: Obj, context: Obj, transactionNum: 7, httpResponseCode: 200, httpResponseText: "\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n//isc_RPCResponseSt..."[3956], xmlHttpRequest: [object XMLHttpRequest], transport: "xmlHttpRequest", status: -1, clientOnly: undef, httpHeaders: Obj, isStructured: true, callbackArgs: null, results: Obj, affectedRows: 0, data: "org.postgresql.util.PSQLException: ERROR..."[3717], invalidateCache: false, isDSResponse: true, startRow: 0, endRow: 0, totalRows: 0}
If I try to hit the DataSource Generator from the Tools window in http://localhost:8080/docs/resources/explorer.html in attempts to open http://localhost:8080/tools/dsGenerator.jsp which is a 404.
Should I expect to be able to generate datasources from postgres tables? I know batch generation is a feature of the enterprise licence, but I'd was expecting single generation to be part of the Pro licence.
Many thanks
Comment