Where Jubula keeps its default tests database? - database

I would like to access Jubula's default database from outside the Jubula or, at least, copy it entirely and move to another computer. There is a reason a can not access it from inside and export tests as XML. Is there a way to do it?

it's using the H2 database by default. It is stored in your user's libriary. I don't know if it's possible to access it from other applications or another machine, but I recommend you not doing that.
What you want to do, is to set up a "conventional" database - like MySQL or Postgre -, and store your tests there. It has some benefits; users can access it, at the same time; you can easily make backups, etc. Just don't forget to install the Jubula Database Drivers like I did.
To save existing tests ("copy it entirely") into this new database, you have to export all Projects to XML. Then disconnect from your H2-database, and select the new database from your connections. Then import the XML file you've just exported, and all your tests will be there. You'll find these commands under the Test menu-section.

Related

how to mirror a whole database cluster in postgresql

I'm using a postgresql (9.6) database in my project which is currently in development stage.
For production I want to use an exact copy/mirror of the database-cluster with a slightly different name.
I am aware of the fact that I can make a backup and restore it under a different cluster-name, but is there something like a mirror function via the psql client or pgAdmin (v.4) that mirrors all my schemas and tables and puts it in a new clustername?
In PostgreSQL you can use any existing database (which needs to be idle in order for this to work) on the server as a template when you want to create a new database with that content. You can use the following SQL statement:
CREATE DATABASE newdb WITH TEMPLATE someDbName OWNER dbuser;
But you need to make sure no user is currently connected or using that database - otherwise you will get following error.
ERROR: source database "someDbName" is being accessed by other users
Hope that helped ;)

How to take all scenarios backup in odi in one go

How to export all the scenarios in odi in one go to make a local backup. Each scenario must be imported as single unit.
The OdiExportAllScen tool can be used in a package or a procedure to export all the scenarios. If there is no need to save the passwords that might be linked to dataserver, the export key can be left blank but Export without Cipher Text data has to be set to Yes.
Execute the package and make sure you use the local agent for a local export, not an agent on the server.

keycloak external database schema

I'm starting to configure Keycloak to run on production environment and I need to use a database in order to run more than one instance with a single configuration repository. I'm using Oracle as SGBD.
But I didn't find the scripts to create the database in the Keycloak's git.
Does anyone knows where can I find them?
You don't need to specifically run a separate set of SQL files. Keycloak will run it for you on first startup.
A bit of advice as it's not really obvious at first - you'll either need to remove and install the default Keycloak data source (KeycloakDS) or manually modify the standalone.xml to point to the setup you want. It took me a little bit to figure out the order that I needed to do things.

Export MSSQL DB, Import in shared environment

We are in the process of trying to migrate from a VPS to a shared environment. The VPS is running Studio Express 2005 so is therefore limited quite a lot in functionality in terms of exporting.
I have managed to export a database in .bak format and upload (Restore) it to the shared environment.
However, here comes the problem, the schema has come with the database. Causing problems when connecting via asp.
The table name structure is as follows [SCHEMA].[TABLE_NAME].
The shared environment does not allow for changing of schema or many advanced features. (Its running myLittleAdmin).
So I guess the schema changes would have to be done on the database, then exported then imported.
Ps. I'm new to MSSQL and more experienced in MYSQL.
Ok So I have found a solution to this.
Export the schema from Studio Express using Right Click > Tools > Generate Script.
Execute this script on the server.
Open this file, find and replace the old user with your new one.
Use a tool such as this one http://sqldumper.ruizata.com/ (SQL Dumper) to export the DB to .SQL.
Find and replace on this file, again for the old user to the new.
Copy this SQL and execute it on the server.
Job done!
Joe

executing EntityFramework4Domain.edmx.sql

I'm creating an application that uses Entity Framework 4 as the ORM. I'm using the designer and have generated the Domain.emdx.sql file to create the database.
So far, I've just run that edmx in sqlserver manually to create the db, but I'm now working on a lightweight installer and I'd like to connect to the db if it exists and run the sql script to create the database, after which I'll use my repositories to insert all of the default values that the db should be populated with.
I would like to be able to load the edmx.sql file so that it will always take the most current changes without having to copy the contents of that file into some resource manually, but I can't seem to find out how to get at its contents in code. It's not in the build folder and it doesn't appear to be directly accessible in code.
How might I do that?
You can try using the CreateDatabaseScript method. It will provide you with the script.
However, looks like you need the CreateDatabase method of the ObjectContext class, this method will simply create a database.

Resources