How do I determine the default HSQL database connection information in Talend Studio? - hsqldb

I am new to Talend Studio. I am doing data profiling using Talend Studio enterprise version 7.3. Generating PDF reports has gone smoothly.
Our group would like to produce some output that is different than what is automatically provided, so we would like to query the underlying reporting database. If I go to the Generated Report Settings pane, there is a Database Connection Settings area with a Db Type of HSQL. Clicking the Check button causes a popup that says "Connection successful and Datamart well configured", as shown below.
Great! Unfortunately, I have not been able to find the name of the database, so that I could connect to it and inspect it using an IDE. For example, I've read that I should be able to connect to the HSQL database using its built-in GUI query tool called DatabaseManager like so:
java -cp ../lib/hsqldb.jar org.hsqldb.util.DatabaseManager
and then setting the config to:
jdbc:hsqldb:file:databaseName
But what is the "databaseName"? Is it specified in a properties file or XML file somewhere?

Related

Schema published but not seen in BI Server with jpivot

I created an schema in Schema Workbench and publish with no errors, but when I got in BI Server with the standard user admin, I choose New->jpivot, then it display the name of the schema I created but it does not display the cube. For reference the error I get from catalina.out is:
17:11:45,174 ERROR [PentahoDataSourceResolver] PentahoXmlaServlet.ERROR_0002 - IDatasourceService.UNABLE_TO_INSTANTIATE_OBJECT
org.pentaho.platform.api.data.DBDatasourceServiceException: javax.naming.NameNotFoundException: Name [Esquema Salario] is not bound in this Context. Unable to find [Esquema Salario].
Name [Esquema Salario] is not bound in this Context errors usually appear if you use JNDI name, which is not defined on your system. So, I assumed, that this is the name of the datasource, which you reference while publishing Mondrian schema files to BI server.
Xml file with Mondrian schema definition generated by Schema Workbench does not contain any information regarding how to connect to database. So, you need to specify these details when you upload your schema file on BI server (It's done on step 4 below).
But first you have to create the connection itself (steps 1-2):
Create new JDBC datasource:
Define connection parameters:
If cubes still don't appear after these steps, you may republish your cube: follow same steps as in step 1, but select "Analysis" instead of "JDBC" in the end.
Upload the xml file, generated by schema workbench and select the datasource, which you have created on step 2. .
If cube still does not appear - check your log again. If you see the same Name is not bound error, you may try to restart your BI server application (new connections usually get recongnized immediately, but if you had a connection with same name before, than you might need to restart tomcat).
If that does not work, than once again, check log files. I guess, you'll have some different error in this case.
I had the same problem as the OP (blank screen when clicking New View) with the latest version of Pentaho BI server 7.1 (latest at the moment) and even with the 6.0 version one, Pivot4J SNAPSHOT 1.0 plug in version (latest as of today), Schema Workbech 3.14 (latest as of today).
And as, in line with OP, my catalina.out log was also spitting the Name [DatasourceName] is not bound in this Context. Unable to find [DatasourceName].
After several trials and errors I noticed the problem showed up when I checked the "Register the XMLA Data Source" when publishing the schema on Schema Workbench. So to fix the problem I just unchecked it before publishing.
Another way to fix this is going to the Manage Datasources option on the BI server, Import Analysis, choosing the schema created by Schema Workbench, AND manually setting the data source parameter value EnableXmla to false and saving changes. Now the schema should show up when clicking on Create New > Pivot4J view.

IntelliJ cannot visualize Database

I have a database I connect to using the IntelliJ Built in tool, and it connects properly to the test database and displays it, however, it doesn't display the tables with another database. I then tried connecting with the open source tool SQL Workbench, with the same information and it does properly connect to the database and displays the tables.
test database:
other database:
other database in SQL Workbench:
When I click "Test Connection" In IntelliJ it connects properly for both the test and the other database, however one isn't actually displaying the tables.
How can I fix this?
Figured out what was wrong:
In the Database configuration file if you go to "Schemas & Tables" you can tick and untick what to show.
While I had never unticked anything, ticking the proper schema and adding it allowed me to visualize my database properly.

Can't create database in SQL SSAS

I installed Microsoft SQL Analysis Service because I need it to run a forecast analysis from Excel using the Data Mining Plug-in.
When I open MS Management Studio and connect to the SSAS I don't know how to create a new database.
When I right-click over Databases there is nothing like Create Database or New Database.
This is the image of my problem:
Well... I solved my problem reinstalling the suite selecting all of its options.
I still don't know what may cause this problem if not chosen in the instalation options but now I have the New Database option and could finish my job.
Thanks.
I managed to solve this problem by switching Analysis Services from Tabular to Multidimensional mode:
Stop SQL Server Analysis Services service
Go to the config folder, e.g. C:\Program Files\Microsoft SQL Server\MSAS15.SQL2019\OLAP\Config
Copy file msmdsrv.ini to another folder (you can't edit it here directly)
Open the copied file and search for the DeploymentMode xml tag
Set the value to zero
Save the file, copy it back to the Config folder
Start the service
You can use SQL Server Management Studio to create a new, empty database on an instance of SQL Server Analysis Services.
To create an Analysis Services database
Connect to an Analysis Services instance.
In Object Explorer, expand the node for the connected Analysis Services instance.
Right-click the Databases node of the Analysis Services instance and select New Database.
In the New Database dialog box, in Database name, type the name of the new database.
In Impersonation, provide impersonation information for the new database.
In Description, type the optional description for the new database.
Click OK.

VS LoadTest does not save results into the SQL Server

I am performing a Load Test using VS, but the results are not saved in SQL Server.
When I run the test, the table LoadTestRun is populated with data, but when the test is done, the table LoadTestTestSummaryData stays empty.
Let me know if you need more information.
Thank you
As pre-steps you need for Performance and Load Testing with Visual Studio:
install and configure Visual Studio ULTIMATE.
SQL Server (e.g SQLEXPRESS 2012) (both SERVER & MANAGER) e.g.
Be sure that SQLEXPRESS service is running. You can run SQL Server Configuration Manager and start it manually. Be careful for the correct INSTANCE_NAME. Also in Task Manager > Services. Next go to Start menu and find VS2012 Cross Tools Command Prompt. Type the following:
cd C:\ Program Files (x86)\Microsoft Visual Studio 12.0\Common7\IDE
and
SQLCMD /S localhost\sqlexpress /i loadtestresultsrepository.sql
This will create Load test DB schema that is required for VS 2012 Load tests.
On the Load Test toolbar, choose Manage Test Controllers. The Manage Test Controllers dialog box is displayed.
In the Load Test Results Connection String, click the browse button (…) to display the Connection Properties dialog box.
Note
If you change the connection string for a controller, then you must select the controller.
In Server Name, type localhost\sqlexpress or the name of the server that you used in step 2 such as ContosoServer1.
Under Log on to the server, choose Use Windows Authentication.
Under Connect to a database, choose Select or enter a database name. Select LoadTest from the drop-down list box.
Choose OK.
All these steps has to be executed in order to get the proper level of integration between VS, SQL ( and maybe Excel for reporting). I suspect that
table LoadTestTestSummaryData stays empty.
because you are missing one of the above mentioned steps.
Could you get to database where you saved your result in, should be something in \sqlexpress in default? if only one table, there could be something wrong with Visual Studio. If you didn't get any table from load test, I would suggest you reset your follow this MSDN link and see what you may have missed:http://msdn.microsoft.com/en-us/library/ms318550.aspx

How to change the connection in Sql Server Data Tools Editor in Visual Studio

My goal is to keep SQL Server stored procedures under source control. I also want to stop using SQL Server Management Studio and use only Visual Studio for SQL related development.
I've added a new SQL Server Database project to my solution. I have successfully imported my database schema into the new project, and all the SQL objects (tables, stored procedures) are there in their own files.
I know that now if I run (with F5) the .sql files then my changes will be applied to my (LocalDB). This if fine, but what if I want to very quickly run something on another machine (like a dedicated SQL Server shared by the entire team)? How can I change the connection string of the current .sql file in the Sql Server Data Tools editor?
I have the latest version of Sql Server Data Tools extension for Visual Studio 2012 (SQL Server Data Tools 11.1.31203.1). I don't know if this is related to the current version, but I cannot find anymore the Transact-SQL Editor Toolbar.
I have also tried to Right-click on the sql editor, choose Connection -> Disconnect. If I do the reverse (Connection -> Connect...) the editor directly connects automatically (probably to my LocalDB), without asking me a dialog to choose my connection.
Another strange thing I've observed, if I try to run a simple SQL query (like select * from dbo.ApplicationUser I receive the following message (even if the autocomplete works):
Thanks.
(Note: I have the same issue with Visual Studio 2013)
Inspired by srutzky's comments, I installed the latest SSDT pack (12.0.41025). And bingo, like srutzky said there is a Change Connection option. But what's more, you can specify your Target DB by right clicking on the Project in the Solution Explorer, and going to Properties->Debug and changing the Target Connection String! If you're stuck on an older SSDT, then the below instructions will still work.
For SSDT 12.0.3-
I've also been plagued by this problem! My solution is below, but it has some Pros and Cons to it...
SOLUTION
I'm assuming that you are using a SQL Server Project in VS (I'm using VS2013 and SQL Server 2012).
Right click on your .sql file in the Solution Explorer and view Properties.
Change Build Action to None.
If the file is open for editing, then close it.
Reopen the file, and the T-SQL Editor should appear at the top.
Click Connect, and you will connect to your (localdb).
Click Disconnect.
Click Connect again and the SQL Server Connection dialog should appear.
Switch the connect string of '(localdb)\Whatever' to '.' (for some reason using '(localhost)' didn't work for me).
Voila, you should now be able to query against your SQL Server DBs! Rinse and repeat for every file you want this capability with... :/
PROS
You can finally run queries directly against your SQL Server DB
Your code can be organized in a nice VS solution (SSMS doesn't allow folders! :/)
You can (after switching Build Action setting back) Build the project
CONS
I'm not seeing any autocomplete/intellisense against the remote DB, although if you import your DB, then you could gain the intellisense from that
Requires each file to switch Build Action to None
This should be a fairly simple and straight-forward thing to do, that is, if you are using SSDT version 12.0.41025.0 (or newer, one would suppose):
Do either:
Go to the SQL menu at the top of the Visual Studio window
Right-click inside of the SQL editor tab
Go to Connection ->
Select Change Connection
Then it will display the "Connect to Server" modal dialog window.
If you do not see the options for "Disconnect All Queries" and "Change Connection...", then you need to upgrade your SSDT via either:
Visual Studio:
Go to the "TOOLS" menu and then "Extensions and Updates..."
Direct download:
Go to: http://msdn.microsoft.com/en-us/data/tools.aspx
The fastest way to achieve this is create a new SQL Connection, copy and paste the code then execute.
What I do is Tools->SQL Server->New Query.
Enter the database credentials (And make sure that the Database at the top is correct - I have hundreds of sp's in my master db on local :) )
Copy the source code from the editor, paste into the new query window.
Then Execute (CRTL-Shift-E).
You can leave this 'scratch' window open and pinned for easy access for subsequent executes.
If you want to deploy (i.e. publish) the entire database then you can setup a publish destination for each server, right click on the xml and select publish..