How can I copy an already existing Pentaho Kettle Job with its settings ?
I did selected all and copy selected entries to clipboard but it didn't copy the settings of the transformations.
I found a solution: I copied the whole .kjb file and renamed it
Related
i wanted to try to run the pentaho from Linux Centos 7.
In the server there are no GUI for it, so i can't open the Spoon GUI where we usually drag and drop the components.
If we use the Spoon, we can change the Database Connection by clicking the Database Connection then re-type the host.
But how do i do that if i can't open the Spoon? Is there a file or something where i can change those?
All transformation and job files are just XML.
You can edit a transformation in your laptop with the correct parameters, save it, find the relevant XML snippet, copy, open the ktr on the server in a text editor, delete the old db connection and paste in the new one.
It may actually be a bit tricky if you mess something up, but with a few tries you should have it done.
You can use JSON file to change database connection in Pentaho Data Integration without using GUI.
Set variable and database connection value in that variable inside that JSON file so that next time you just drag and drop JSON file in server where you cannot open Spoon GUI to change the database connection values.
Let me explain how we do it.
First create a transformation where we take JSON file as input and set that value into variable to later use that value anywhere inside that job as ${variable_name}.
JSON file looks like this ...
Browse and add your JSON file ...
Go to Fields tab and Select field ...
Now in set variable step go to Get Fields ...
Now let us suppose we have created these variables in JSON file now we use these variables to create a database connection.
${mysql_host}
${mysql_port}
${mysql_username}
${mysql_password}
${mysql_database_name}
like this ...
In this way you can build your ETL with dynamic database connection in Pentaho Data Integration. Just replace JSON file in server then database connection will be changed in that whole ETL package.
This example ETL package can be downloaded from this link:
Download
I need some help with a problem:
I have a *.bak file that i need to check for its contents on a certain table, however because of circumstances I cannot restore it on the server.
I tried to open it using Libreoffice calc, without success, because of few workplace circumstances using excel is not an option.
How can i open and search for the data in this *.bak file?
You won't able to see anything on *.bak file. If you want to make a verification I suggest that you make a database script export (structure and data) and compare it with the previous version (without certain table) and if that table is refereed inside that script.
I'm using h2database version 1.4.200 with hibernate for saving in database file.
My programs needs to regulary save backup and I don't care about corruption's file's problems.
After looking the documentation : http://h2database.com/html/features.html#database_file_locking
I decided to use parameter LOCK_FILE=NO. I saved my models and keeped the entity manager opened. When I tryed to copy the db file "data.mv.db", my database file was always locked even if I used Lock_FILE=NO.
Parameter LOCK_FILE=NO, does it work correctly ?
There is a alternative for copying speedly my db-file in java ?
Any attempt to copy the file when database is in use is a way to get a possibly corrupted backup.
H2 has BACKUP command for online backups.
BACKUP TO 'filename.zip'
This command creates a ZIP archive with a consistent copy of the database file.
Is it possible to copy a database to a new server? I just want to have the database on a new server because I need to make some tests. I didn't have much experience with servers.
Follow this steps :
Run your SSMS
Right click on the database you want to copy
In the Popup menu , go to Taches , then click Offline
Right click on the Database again in the popup menu , Taches -> Detach
Open the folder ..\MSSQL\DATA , copy Yourdb.MDF and YourDB_log.LDF files to the folder of the new Instance.
Now you can Attach both Databases and work on it in both instance.
Another way:
Run Your SSMS
Right click on the Database you want to copy
In the popup menu , Taches -> Copy the database...
Follow the steps on the Wizard
You can select option if you want to keep the database ONLINE when it is being copied.
You can also select option of MOVE or COPY database as well.
When the process is over it will show the success message and database will be copied to another server.
Note:
1- The Copy Database Wizard is not available in the Express edition.
2- The Copy Database Wizard cannot be used to copy or move databases that are/have:
System.
marked for replication.
marked Inaccessible, Loading, Offline, Recovering, Suspect, or in Emergency Mode.
data or log files stored in Microsoft Azure storage.
Also , a database cannot be moved or copied to an earlier version of SQL Server.
Updtae:
If there is no Copy database option , then you can Copy Databases with Backup and Restore.
For more information about it MSDN.
No experience? No problem, backup the database.
Copy it into the target machine.
Restore DB from device >> open the DB backup file.
At this point you have the entire DB without missing any schema objects such as foreign keys.
Finally delete all sql logins that the DB came with and recreate them manually as you test access.
Once you are comfortable with this operation you can go ahead and get more experience using some of the techniques describe above which are recommended if you have a large DB to restore and so on.
How to restore the DB on SQL Server Management Studio
Steps:
1. On “Object Explorer” panel right-click on “Databases” and selected Restore Database
Select “Device” and browse database location.
note: Copy the .bak file locally before restoring.
The DB information will auto-populate the window, you can edit the name of the DB to be restored.
Go to the “Files” page and check the “Relocated all files…” box.
Select existing folder locations for Data and Log files.
HIT OK
i used management studio to import data from Excel to a SQL table, and on the final step saved the ssis package to the database.
now i want to re-run the saved package on a new excel file i get as a data dump from another system.
the excel file is identical and only the data changes.
how can i re-run the saved ssis package on the new file?
i am just over-writing the old excel file with the new one and expect the ssis job to just pick up everything and run as it did the first time.
You should be able to run DTExecUI from the command prompt. From here select the server you want to use and the package.