Problems when creating a virtual database from a text file using Teiid
rok.kuzem May 15, 2015 3:43 AMHello,
First thing first, my configuration is teiid 8.9.0 which runs on windows 8.1 java 1.7.0_79, and on the client site I have Eclipse 4.4 with teiid designer 9.0.1 and java 1.7.0_76. I have my workspace locally on client computer I am trying to follow this tutorial, but I am stuck at a step where I should preview the data for MainTable (- Now we can preview the data for “MainTable”:). As I said I have workspace on local computer and my data.txt file is in the project folder. Everything is connected succesfully, and the path to the folder is right, but when I run the sql gives me File not found.
This is the SQL:
SELECT
letter, number
FROM
(EXEC TextFileModel.getTextFiles('data.txt')) AS f, TEXTTABLE(file COLUMNS letter string, number string HEADER) AS A
This is the error:
select * from "TextViewFile"."MainTable"
org.teiid.runtime.client.TeiidClientException: java.lang.RuntimeException: Remote org.teiid.core.TeiidProcessingException: TEIID30504 TextFileModel: File not found data.txt
Elapsed Time: 0 hr, 0 min, 0 sec, 330 ms.
Another error at the same time:
ERROR: org.teiid.datatools.connectivity.ui
java.lang.NullPointerException
at org.teiid.datatools.views.ExecutionPlanView.displayHTMLExecPlan(ExecutionPlanView.java:574)
at org.teiid.datatools.views.ExecutionPlanView.updateContents(ExecutionPlanView.java:605)
at org.teiid.datatools.connectivity.ui.TeiidAdHocScriptRunnable.handleShowExecutionPlan(TeiidAdHocScriptRunnable.java:259)
at org.teiid.datatools.connectivity.ui.TeiidAdHocScriptRunnable.access$0(TeiidAdHocScriptRunnable.java:251)
at org.teiid.datatools.connectivity.ui.TeiidAdHocScriptRunnable$UpdatePlanViewRunnable.run(TeiidAdHocScriptRunnable.java:293)
at org.eclipse.ui.internal.UILockListener.doPendingWork(UILockListener.java:167)
at org.eclipse.ui.internal.UISynchronizer$3.run(UISynchronizer.java:165)
at org.eclipse.swt.widgets.RunnableLock.run(RunnableLock.java:35)
at org.eclipse.swt.widgets.Synchronizer.runAsyncMessages(Synchronizer.java:136)
at org.eclipse.swt.widgets.Display.runAsyncMessages(Display.java:4147)
at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3764)
at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine$9.run(PartRenderingEngine.java:1151)
at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:332)
at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine.run(PartRenderingEngine.java:1032)
at org.eclipse.e4.ui.internal.workbench.E4Workbench.createAndRunUI(E4Workbench.java:148)
at org.eclipse.ui.internal.Workbench$5.run(Workbench.java:636)
at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:332)
at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:579)
at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:150)
at org.eclipse.ui.internal.ide.application.IDEApplication.start(IDEApplication.java:135)
at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:196)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:134)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:104)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:380)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:235)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:648)
at org.eclipse.equinox.launcher.Main.basicRun(Main.java:603)
at org.eclipse.equinox.launcher.Main.run(Main.java:1465)
at org.eclipse.equinox.launcher.Main.main(Main.java:1438)
This is also connected to the same operation
ERROR: Unhandled event loop exception
org.eclipse.swt.SWTException: Failed to execute runnable (java.lang.NullPointerException)
at org.eclipse.swt.SWT.error(SWT.java:4441)
at org.eclipse.swt.SWT.error(SWT.java:4356)
at org.eclipse.swt.widgets.Synchronizer.runAsyncMessages(Synchronizer.java:139)
at org.eclipse.swt.widgets.Display.runAsyncMessages(Display.java:4147)
at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java:3764)
at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine$9.run(PartRenderingEngine.java:1151)
at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:332)
at org.eclipse.e4.ui.internal.workbench.swt.PartRenderingEngine.run(PartRenderingEngine.java:1032)
at org.eclipse.e4.ui.internal.workbench.E4Workbench.createAndRunUI(E4Workbench.java:148)
at org.eclipse.ui.internal.Workbench$5.run(Workbench.java:636)
at org.eclipse.core.databinding.observable.Realm.runWithDefault(Realm.java:332)
at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Workbench.java:579)
at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.java:150)
at org.eclipse.ui.internal.ide.application.IDEApplication.start(IDEApplication.java:135)
at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:196)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:134)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:104)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:380)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:235)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:648)
at org.eclipse.equinox.launcher.Main.basicRun(Main.java:603)
at org.eclipse.equinox.launcher.Main.run(Main.java:1465)
at org.eclipse.equinox.launcher.Main.main(Main.java:1438)
Caused by: java.lang.NullPointerException
at org.teiid.datatools.views.ExecutionPlanView.displayNoExecPlanMessage(ExecutionPlanView.java:564)
at org.teiid.datatools.views.ExecutionPlanView.displayHTMLExecPlan(ExecutionPlanView.java:577)
at org.teiid.datatools.views.ExecutionPlanView.updateContents(ExecutionPlanView.java:605)
at org.teiid.datatools.connectivity.ui.TeiidAdHocScriptRunnable.handleShowExecutionPlan(TeiidAdHocScriptRunnable.java:259)
at org.teiid.datatools.connectivity.ui.TeiidAdHocScriptRunnable.access$0(TeiidAdHocScriptRunnable.java:251)
at org.teiid.datatools.connectivity.ui.TeiidAdHocScriptRunnable$UpdatePlanViewRunnable.run(TeiidAdHocScriptRunnable.java:293)
at org.eclipse.ui.internal.UILockListener.doPendingWork(UILockListener.java:167)
at org.eclipse.ui.internal.UISynchronizer$3.run(UISynchronizer.java:165)
at org.eclipse.swt.widgets.RunnableLock.run(RunnableLock.java:35)
at org.eclipse.swt.widgets.Synchronizer.runAsyncMessages(Synchronizer.java:136)
... 24 more
I have tried to to change the data.txt in another folder, but it didn't help, I have also put it on the server side and show the path but then I got another error. If someone could help me I would really appreciate it!
Regards