For example in this case I have extracted the workbench schema ps-ce-3.11.1.0-386 in my desktop. So i run the command prompt in Windows by click Start>>Search>>Type CMD and press ENTER on the keyboard. Once it is in command prompt usually the position of the folder is something like C:\Users\PC USER 1 (Note: for different computer might be different directory).
Since we know the directory location of the workbench is in desktop and the name is psw-ce-3.11.1.0-386\schema-workbench so i just type the following command to change the directory location to that file.
cd psw-ce-3.11.1.0-386\schema-workbench and press "ENTER" on the keyboard. Now the directory will change to C:\Users\PC USER 1\Desktop\psw-ce-3.11.1.0-386\schema-workbench>workbench in the command prompt.
In this directory C:\Users\PC USER 1\Desktop\psw-ce-3.11.1.0-386\schema-workbench>workbench. You can run the "workbench.bat" file by typing workbench or workbench.bat and the error message below appear.
C:\Users\PC USER 1\Desktop\psw-ce-3.11.1.0-386\schema-workbench>workbench
WARNING: Using java from path
DEBUG: _PENTAHO_JAVA_HOME=
DEBUG: _PENTAHO_JAVA=java
'"java"' is not recognized as an internal or external command,
operable program or batch file.
C:\Users\PC USER 1\Desktop\psw-ce-3.11.1.0-386\schema-workbench>
How to solve this problem
1. Download Java Environment from Oracle Downloads make sure to download the correct version i am using Windows 10 (32 bits) so download the Windows X86 version
2. Once download and install the Java - In this case I've installed in C:\Program Files directory
3. Once installed go to the Pentaho psw-ce-3.11.1.0-386\schema-workbench folder and edit the workbench.bat using notepad++
4. Look for this section
for %%i in ("plugins\*.jar") do call cpappend %%i
set PENTAHO_JAVA=java.exe
call "%~dp0set-pentaho-env.bat"
"%_PENTAHO_JAVA%" -Xms1024m -Xmx2048m -cp "%CP%" -Dlog4j.configuration=file:///%ROOT%\.schemaWorkbench\log4j.xml mondrian.gui.Workbench
rem End workbench.bat
5. Change the java.exe with the installed java including its directory location so that it reads like so set PENTAHO_JAVA=C:\Program Files\Java\jre1.8.0_73\bin\java.exe
6. Save the file and run the workbench.bat again - it should be working
No comments:
Post a Comment