Informix database from unix to Linux - unix

We are going to migrate .net applications with Informix database as datasource systems from Unix to Linux server.
The informix databases are available in the existing Unix server.
As part of impact analysis we need to identify which are all other application types that might get impacted due to this migration of informix database system from unix to linux server.
In simple terms is there a way to identify what are all the applications that are using this existing informix database on unix system.
Thanks

You can check all Informix sessions (connections) by examining sysmaster:syssessions table:
select * from sysmaster:syssessions
There are username and hostname columns which will help you to identify applications using Informix database.

Related

Can you connect to CosmosDB from SSAS (Tabular) using the ODBC driver for Cosmos?

I have followed the instructions for setting up a new ODBC connection to CosmosDB. I would like to use this ODBC connection in an SSAS tabular project but I don't see a way to do that. I am on SSDT 15.1. When I click the "Others" data source for OLEDB/ODBC in SSAS, it only gives me build options for OLEDB. It's not clear how I would use this to connect to my CosmosDB ODBC.
Has anyone figured out how to do this? According to Microsoft it is possible but they have no instructions for it.
It is possible. Launch the "ODBC Data Sources (32-bit)" app and setup a system DSN as described in this article. Then open "ODBC Data Sources (64-bit)" and setup a system DSN with the exact same name as the 32-bit DSN. The reason is that Visual Studio is 32-bit so when performing some steps it requires a 32-bit driver, but once SSAS loads the table into memory that occurs in a 64-bit process which requires the 64-bit driver. Setup these DSNs on your workstation and on the workspace server (local if using the integrated workspace or on a dev server if using a remote workspace).
Using ODBC drivers inside Analysis Services Tabular doesn't seem to be very well documented. Basically you need to use the OLEDB for ODBC driver.
When creating a new connection in Visual Studio in your SSAS model, instead of choosing the driver from the dropdown, just type in the following connection string:
Provider=MSDASQL;DSN=YourDsnNameHere
If you prefer inline connection strings that make deploying easier to do without ODBC DSNs then you can use this connection string:
Provider=MSDASQL;DRIVER={Microsoft DocumentDB ODBC Driver};Host="https://yourcosmosdbname.documents.azure.com:443/";AuthenticationKey="authKeyHere!";LocalSchemaFile="c:\folder\yourCosmosSchema.json";KeyEncrypted=true;NumberOfRetries=5;DSNType=0;Consistency=1
Regardless of which connection string you will probably have to write a query such as select * from CollectionName rather than picking from the table list.
If you are using 1400 compatibility level models (Analysis Services 2017 or Azure Analysis Services) then you should consider using the modern get data experience which has native Cosmos DB integration that's a lot more polished.

How to connect to an Informix Database from an ASP.NET script?

I've never coded in ASP.NET, but I've been a web (PHP) developer for almost 3years now,
Problem is I've never coded in anything .NET after I completed my studies and I've never worked with IIS and MS Servers either.
I need to create a connection from an ASP.NET (VB) script to an Informix database.
google took me to this; IBM Informix connection example but I haven't a clue how to add these drivers to IIS, the IBM Informix Client SDK is installed on the server, but when I open the dialogs in IIS to add them as Handlers, I'm prompted for things I don't know the meaning of, I haven't found anything that says tutorial that is of any help and nor have I found anything on stack overflow.
I feel like an African stuck in China, what the hell do I do first and where do I go?
I have used ODBC in the past to connect to Informix, like this. If you have an Informix DBA, he will provide the values for host, server, and service. host is the name of the host machine where the database server resides. service is the service name in the services file but it actually maps to the port Informix listens. Server is the actual server.
string connectionString = "Driver={INFORMIX};host=myhost;server=myserver;service=23300;protocol=onsoctcp;database=dbase;uid=user;pwd=pass;client_locale=en_US.CP1252;db_locale=en_US.8859-1;"
OdbcConnection conn = new OdbcConnection(connectionString);
conn.Open();
For more connection string samples, see here.
To test, you can create an ODBC data source and test the connection without writing any code.
Okay, so as it turns out, I didn't find anything solid, so I went to find help in a clients office from an experienced .NET developer.
I was told to create a DSN on the server machine using ODBC, in the steps explained here
after that I referred to the DSN connection in the connection string, like this;
DSN=myDsn;Uid=myUsername;Pwd=p%W$d;
And I had to add impersonation to my asp.net scripts, as is done here using the same user I was logged in as when creating the DSN connections in ODBC
I had similar issues when trying to connect to an Informix DB from ASP.NET Console Application, but eventually found a way to connect! Here is the connection string i used that did the trick:
Database=db_cra;Host=192.168.160.207;Server=sipccx1_uccx;Service=1504;Protocol=onsoctcp;UID=MyUserId;Password=MyPassWord;DB_LOCALE=EN_US.UTF8;CLIENT_LOCALE=EN_US.UTF8;
Notes: The DB_LOCALE and CLIENT_LOCALE were the missing puzzle pieces for me. Also, "Service" means "Port" and "Server" is Informix instance name - defined in the database configuration (see: Finding Informix DB Server )
I downloaded and installed the Informix Client SDK provided by IBM and found that it comes with sample code (for both C# and VB). The path to the samples are C:\Program Files\IBM Informix Client SDK\demo\dotnetdemo\quickstart\cs
Add your connection string to the conninfo.xml file and run the file named helloworldconnect.cs as a console app to test connection. Your results will spit out into a file named "log.txt" (found in the bin/Debug folder).
BTW - I downloaded the 64 bit version of the "IBM Informix Client SDK". Trying to run it gave me "BadImageFormatException" so i had to switch my Platform Target to x64.
The SDK readme docs say it is IBM Informix .NET Provider Version 4.10.FC5 released on March 26, 2015. This link should give you a list of Windows 64 bit drivers (you will need to create an IBM account to download). On this page you can change the filter settings (top of page) to get other operating systems.
Whew.. now onto pulling data!
One more thing.. this book "IBM Informix Developer's Handbook" (https://play.google.com/books/reader?id=eprEAgAAQBAJ ) is a great resource and its free!

SQL Server Express and SQL Server Compact Edition

I've just built my first Umbraco site and now I want to hand it over for deployment on a web server. However, I built the site on my local machine using Web Matrix, which uses a SQL Server Compact Edition database, which is represented in a .sdf file.
I was a bit uneasy about whether this would be much use to the person I'm passing the site to (they have a number of Umbraco based sites running on this server using SQL Server) - so I installed SQL Server Express and migrated the database from Compact Edition to Express. However (again), I can't seem to find any way of exporting the full database to a file which can then by imported into a database on the web server.
A couple of points I guess - first, is the Compact Edition .sdf file actually enough for someone to take and import a database into SQL Server Standard? Failing that, how would I export the database from SQL Server Express to a file which could be used for this purpose?
Thanks in advance - this is my first foray into .net development so I'm grateful for any help!
You could just give the SQL CE database (.sdf) to the person who manages the web server. The SQL CE database can be run by default on a .NET webserver.
If, for some reason, you want to migrate it to SQL Server, you can do this through Web Matrix (http://www.microsoft.com/web/)
When you have already converted the SQL CE database to SQL Server, you can:
make a backup through the SQL Server Management Studio tool and restore the backup on the web server
or you can use the SQL Server Management Studio tool to script the database to a .sql file which can be executed on the web server
I prefer the first option.

Connect to Remote Oracle database from ASP.NET

My course requires me to connect to an Oracle database server at the university for my project. I am provided with a url (like oracle.xyz.edu) and username and password. How can I connect to the database from Visual Studio. I have only dealt with SQL Server 2008. I don't know how to go ahead with setting up the database. I tried to install Oracle Instant Client, but could not find a setup exe to install. The instant client download zip consists of a set of files. Where can I find the steps to connect to Oracle database from VS.
Do you need to use the Oracle Instant Client? Or would it be acceptable to you to download and install the full version of the Oracle client?
The full version of the Oracle client is generally what ought to be installed on a developer machine. The Instant Client is a very slimmed down version of the client that is designed for developers to distribute along with their Windows applications on machines that do not have or need any way to access the database other than via the application. As a developer, I'd strongly recommend the full version of the Oracle client if only because it includes various additional utilities like SQL*Plus and SQL*Loader.
The full Oracle client is available for download from OTN on the same page that the database is available. For example, the Oracle 11.2 client for 64-bit Windows is a 615 MB download on the OTN site.
Don't use ODBC. Use ODP.NET (Oracle's Instant Client) Oracle Data Provider for .NET. (Read technical notes in provided link.)

Can I use the SQLite as a db storage for cloud-based websites?

Has anyone ever launched cloud-based apps / websites that use a local SQLite DB as the primary data source?
Are there any warnings about this?
My environment:
C# 3.0 app
currently uses a sql server 2008 db
current db size 30 mb-
If you expect a lot of traffic, you really shouldn't. SQLite is meant to be used as a lightweight SQL database, and is not meant for highly concurrent access (since it locks the whole database file) which could be an important requirement in this case.
Read:
Appropriate uses for SQLite

Resources