Library to connect Rstudio to MemSQL Database - r

Is the library needed to connect to a MemSQL database the same as the one used for MySQL?
Would the library(RMySQL) work to establish this connection?

Yes, in general you can connect to MemSQL using the same client libraries as for MySQL. Try it out and ask if you run into any problems.
Nothing directly about Rstudio, but there are many examples of how to connect to MemSQL with various clients at https://docs.memsql.com/tutorials/v6.0/how-to-connect-to-memsql.

Related

R integration with asp.net and ssas

Maybe someone knows if it's possible to send data from ms sql database to R server, so it could calculate some columns and send them back to ms sql again?
I am not that much familiar with R server's integration and I am cautious that is not even possible. If this is not possible, maybe it would be possible to send them from asp.net mvc 5 using integration from .net library, but I do not think that is a good solution because the data can have more then 500k rows so it would be extremely slow.
Querying a database from a server running R requires three things:
Network security that allows you to communicate between the machines
Drivers installed on the R server
Configurations that allow you to connect to the database from R
In general, it is best to have your IT/Ops team take care of the Networking security and the installation of drivers, since these are things that they likely have security procedures around. We recommend using the RStudio Professional Drivers, which are easy to install and designed to work with our products.
Then, when it comes to the connection from R to the database, we recommend using the odbc package, which is a DBI compliant interface to using ODBC drivers. You can acquire the latest stable version from CRAN with install.packages("odbc").
In general, a connection looks something like this:
library(odbc)
con <- dbConnect(odbc(),
Driver = "SQLServer",
Server = "mysqlhost",
Database = "mydbname",
UID = "myuser",
PWD = rstudioapi::askForPassword("Database password")
Port = 1433)
The rstudioapi::askForPassword function will prompt the user for a password and reduce the need to store passwords in code. For more options on securing credentials, there is a dedicated article on the topic. Note that there is also support for DSNs:
# Using a DSN
con <- dbConnect(odbc::odbc(), "mydbalias")
for other reference please visit this url.
Hope it helps.

How to use ODBC to connect to any DBMS

I'm developping a java application and i'm using JDBC to connect to MySQL Database, now i want to use ODBC to be able to get and retrieve data from any DBMS, of course if have access to it. Is there an API or tool to do this ?
What you are looking for is a JDBC-ODBC bridge. There are several available. It is not recommended, instead you should always use a native JDBC driver.

OBIEE connect to impala

I'm trying to connect OBIEE to Impala. Where I try my test, I encounter a problem that I can't
resolved,here comes my steps:
download the Cloudera latest Impala ODBC driver for windows,and import metadata from impala,I can finally successfully see data in Admin Tools like this:
upload the rpd file to the server,and download cloudera impala odbc driver for linux,and configure it,in the end ,I can do it like this which shows I have configure the driver successfully:
I try to create new analysis through 【Create Direct Database Request】 to test weather I can successfully connect Impala, but I can never connect it due to the reason like this,I can never fingure out why:
Is there anybody successfully do it or tell me how I can resolve the problem? Thanks!
I recommend connecting directly to Hive instead. According to Oracle's documentation Impala connectivity is not directly supported. OBIEE is built connect to Hive and Impala is not referenced:
http://docs.oracle.com/cd/E28280_01/bi.1111/e10540/deploy_rpd.htm#BABGIAJH

How to use QXmpp server_example?

I've compiled Qxmpp server_example successfully, but yet dunno
how to connect a client to that server - Example from Qxmpp library. Can anybody suggest smth, I'll be grateful for that stuff.
Do you have an XMPP server that you can connect to? You can setup one locally by using one of these servers: http://xmpp.org/xmpp-software/servers/
Ideally, you'd want to have two instances of the client software on two different physical machines/virtual machines so you can test that the messaging works between two users.

mysql odbc questions

i'd like to use the mysql odbc driver for connecting to my mysql database via my own app.
the problem is that it seems very unstable - i keep getting errors like:
[MySQL][ODBC 5.1 Driver][mysqld-5.5.8]MySQL server has gone away
it seems to be something like a session timeout.
so here's my questions:
- what is causing those errors?
- is there a way to fix it for getting stable connections?
- is it recommended at all using it for coding windows software?
thanks
My guess is you're opening the connection once and leaving it open. At some point, the connection either times out, or some network hiccup is causing the connection to be invalid/closed. The best way to do database access is to open the connection when you need to do work, then close it. Or, alternatively, change your code to support re-connecting when you encounter an error.
Based on discussion in the comments below, I would suggest dumping the access database to a csv file, then using something like PHPMySql to import the data into MySQL.
You can use the BigDump tool to import large databases dumps into MySQL. (via this site)
There are commercial alternatives out there -
OpenLink Single-tier ODBC Driver for MySQL

Resources