odbc

Php/ODBC encoding problem

蓝咒 提交于 2019-12-29 09:22:10
问题 I use ODBC to connect to SQL Server from PHP. In PHP I read some string (nvarchar column) data from SQL Server and then want to insert it to mysql database. When I try to insert such value to mysql database table I get this mysql error: Incorrect string value: '\xB3\xB9ow...' for column 'name' at row 1 For string with all ASCII characters everything is fine, the problem occurs when non-ASCII characters (from some European languages) exist. So, in more general terms: there is a Unicode string

How do I connect to an MS Access database using Perl?

大兔子大兔子 提交于 2019-12-29 08:01:13
问题 I have a .accdb file on my local machine and I am trying to connect to it and read some data from 3 tables within the DB. How do I establish the connection using Perl? So far I have scraped together this much for MS Access, but I am getting errors saying that I am not using the correct driver. Any ideas? my $msaccess_dbh = DBI->connect( 'dbi:ODBC:driver=microsoft access driver (*.accdb);' . 'dbq=C:\path\to\database\databasefile.accdb' ); Thanks! EDIT: Just to clarify, I have no real

Listing ODBC Data Sources in C#

倾然丶 夕夏残阳落幕 提交于 2019-12-29 07:28:38
问题 I'm looking for a properly abstract way to get a list of ODBC data sources from the system in C#. I've tried the "Poking-around-in-the-registry" trick, which I've found works fine in English: RegistryKey reg = (Registry.CurrentUser).OpenSubKey("Software"); reg = reg.OpenSubKey("ODBC"); reg = reg.OpenSubKey("ODBC.INI"); reg = reg.OpenSubKey("ODBC Data Sources"); and then, of course, iterating over reg.GetValueNames() Only problem is that I've discovered on at least one Spanish machine that

Problem with SELECT * in MySQL through ODBC from Microsoft SQL Server

只谈情不闲聊 提交于 2019-12-29 06:17:34
问题 I have a MySQL server as a linked server in Microsoft SQL Server 2008. For the link I use MySQL ODBC Connector version 5.1.8. When invoking queries using OPENQUERY (the only way I found of performing queries), problems occur. Simple queries, such as SELECT * FROM OPENQUERY(MYSQL, 'SHOW TABLES') work fine. Selection of individual columns, e.g., SELECT * FROM OPENQUERY(MYSQL, 'SELECT nr FROM letter') works fine as well, but SELECT * syntax does not work. The query: SELECT * FROM OPENQUERY(MYSQL

Get table names from lotus notes database

匆匆过客 提交于 2019-12-29 05:38:07
问题 I'm trying to write a program that would dump a whole lotus notes database to a file via NotesSQL driver. I'm connecting via jdbc:odbc and have I can execute selects and get data from Lotus notes database here is the code try { System.out.print("Connecting... "); Connection con = DriverManager.getConnection("jdbc:odbc:NRC", "UserName", "Passw0rd1337"); System.out.println("OK"); DatabaseMetaData dmd = con.getMetaData(); String[] tableTypes = new String[] {"TABLE", "VIEW"}; ResultSet rs = dmd

JDBC-ODBC Bridge queries to Access fail when they have accented characters

谁说胖子不能爱 提交于 2019-12-28 19:35:36
问题 I'm sending a query through the JDBC-ODBC Bridge to an Access database from Java, like this: "SELECT * FROM localities WHERE locName='" + cityName + "'" When cityName is a normal string with no accented characters, the resultset is correct. But when cityName happens to be something like LEÓN , SAHAGÚN , that is with accented characters in them, then I get no results. It seems like the query fails in these cases. The same queries when run in MS Access work all right, I also tried with Ms Data

ODBC Password Security in SAS

一曲冷凌霜 提交于 2019-12-28 06:58:54
问题 We want to remove hardcoded passwords from ODBC connection strings in our SAS code, and also prevent any of the passwords from appearing in the SAS log files. There seems to be plenty of whitepapers discussing how to go about this but I either find problems with them, or can't get them working. Prompting the user each time for the PW is not a viable alternative. Also, storing the password in a macro variable is an acceptable approach, as long as you have a way to suppress it from printing to

Save password for ODBC connection to MS SQL server from MS Access 2007

非 Y 不嫁゛ 提交于 2019-12-28 06:16:05
问题 I am in charge for migrating old Access 2007 project to MS SQL server 2008 Express. The first stage is to move all the data from MS Access database to SQL server while keeping the Access forms and reports at the client. So, the data are now moved, an SQL server user (for accessing only that particular database) created, and the tables are linked the Access database via ODBC connection. However, there's one nuisance that should be somehow solved: the Access regularly asks for the user password

ODBC SQL update Statement issue if more than 32,000 characters

孤者浪人 提交于 2019-12-25 14:45:36
问题 Here is the problem: I have one giant string of xml data stored in a (BLOB)field in a table. It holds some strings 70k characters or more at times. I pull it out using an ODBC_Connection. I can import (no problem). I can manipulate the XML and save it back as a string (no problem). I can save the string back into a mySQL field (no problem). The problem comes when i try to save it back to its original field that i pulled it from. If I save the string with less than 32,000 characters, we are

Access 2007 to Oracle 10g linked table — query with flawed results, but no errors thrown

早过忘川 提交于 2019-12-25 12:19:31
问题 Access 2007 databases querying linked oracle 10g tables are returning flawed result sets when using the WHERE clause to filter-out unwanted records. Oddly, some filtering is happening, but not reliably. I can reliably demonstrate/produce the problem like this: Create a *new* database with Access 2007. Create a second *new* database with Access 2007, and then "save-as" 2000. Create a third *new* database with an older version of Access. Run the following query in each database: SELECT STATUS,