odbc

How to connect from ruby to MS Sql Server

Hi Crowd! I'm trying to connect to the sql server 2005 database from *NIX machine: I have the following configuration: Linux 64bit ruby -v ruby 1.8.6 (2007-09-24 patchlevel 111) [x86_64-linux] important gems: dbd-odbc (0.2.4) dbi (0.4.1) active record sql server adapter - as plugin ruby-odbc 0.9996 (installed without an...

When accessing a database over JDBC/ODBC should you create and close the connection for each request?

If you have a class that services requests from other classes for database data when should you hold onto the databse connection and when should you close it and reopen it on the next request? What if it's a service that responds to connections from external applications? (Web service, Ajax, rpc) Is it a good idea to hold a singleton c...

How can I secure connection to SQL Server from Perl DBI?

I need to connect to a secure SQL Server database using Perl DBI. I need to find a way to authenticate the user securely (without fear of eavesdropping, and without storing passwords on the client side). I'm using SQL Server 2008 on Windows Server 2008, and Perl 5.10 on XP. SQL Server supports encrypted connections via something calle...

How do I Import table from an ODBC Database ?

I have an ODBC Database (some third party DB) where I have a bunch of tables. I am able to use 'GetSchema' to get a list of tables in there. I am also abe to utilize SQLBulkCopy to copy Data from these tables to SQL Server tables (only when I have created a Destination table with the same structure in SQL Server). But here is the scenar...

Problem accessing a MySQL database over ODBC

OdbcDataReader q = dbc.Query("SELECT * FROM `posts` WHERE `id`=" + id.ToString()); if (q.RecordsAffected < 1) { this.Exists = false; } else { this.Exists = true; this.Author = q.GetString(6); } The server returns No data exists for the row/column. My database table is structured like this (screencap from phpMyAdmin) By t...

When should I be using Odbc, OleDb, SQLClient? What are the trade-offs

I am starting off with a SQLServer database. So it would seem that I should use System.Data.SqlClient namespace. But, there is a chance that we might shut down our SqlServer database and go to MySql or Oracle. For this reason, I am coming up with a set of standards on how our .Net apps will communicate with the database, so as to make it...

Insert empty BLOB into SQLite DB using ODBC and C++ Net

I'm using a SQLite database to store cover images of books I have in a database. I've got the inserting of BLOBs ok, but when I don't have a cover image for my book I can't seem to get it to insert a null BLOB. I'm using parameters for my insert SQL statement, using ODBC, as shown below: OdbcParameter^ paramCoverImage = gcnew OdbcParam...

Inserting clobs into oracle with ODBC

I'm trying to insert a clob into Oracle. If I try this with an OdbcConnection it does not insert the data into the database. It returns 1 row affected and no errors but nothing is inserted into the database. It does work with an OracleConnection. However, using the Microsoft OracleClient makes our webservices often crash with an AccessV...

Can I specify primary key when linking Oracle view from MS Access?

I need to create a linked table from MS Access to a view in Oracle. I am creating the linked table from VBA using the following DoCmd.TransferDatabase acLink, "ODBC Database", [ODBC connect stuff], _ acTable, mySourceView, myDestinatonTable, , True This is working and creates a link to the Oracle view. However...

ODBC Command does not throw error

I'm working on a VB6 executable that uses ODBC to update a DB2 Table. When trying to update a row that does not exist the program does not throw an error as would be expected. Why would this happen? objAdoConn.Execute("Update T1234 Set A = 'X' Where B = 'y'"); ...

Lost RPC connection to remote Agent error with Oracle connected to Informix

I am having a problem with a simple data importer / updater that takes data from Informix, inserts it into a table in Oracle, and updates a flag in the original table. The set up is this Pro*C program calls a PL/SQL procedure The procedure opens a cursor on Informix, loops through each row insert the data into an oracle table ...

Simple method to test system DSN's?

Is there a simple way to test that a System DSN setup on Windows Server 2000/3 is configured and connects properly? ODBC Data Source Administrator doesn't appear to have anything for this. ...

Data Corruption with MediumText and ASP/MySQL

I have a website written in ASP with a mySQL database. ASP uses the ODBC 5.1 driver to connect to the database. Inside the database there is a varchar(8000) column (the length started small, but the application has evolved A LOT since its conception). Anyway, it recently became evident that the varchar column should be changed into a MED...

exception problem with odbc and C++ causes bizarre database behavior

I have a C++ application (compiled with VS2003 running on windows 2000 server against SQL 2000 database) that ran fine for years and now is crashing. My logging shows that the database connection (ODBC using the SQL Server driver) will be working fine (read and update database) then after an exception throws (and is caught/logged but no...

secure ODBC connection -- oxymoron?

Hello - There are times we need to create an ODBC connection over the "tubes" to one of our customer sites. We would like to provide as much security as possible to our customers, given we are using ODBC and, well... Anyway, there is a checkbox setting in the SQL Server DSN that says "Use strong encryption for data", but absolutely no...

Free Access to DB2 via ODBC

Is there a free option to connect to DB2 via ODBC on within my .NET app? I believe the most common ways require a license: Data Direct $$$$ IBM Client Access Host Integration Server I just want to install an ODBC driver that I could access from a C# app. ...

MySQL ODBC 3.51 Driver UTF-8 encoding

Currently I am migrating MSSQL to MYSQL.I am using the MySQL ODBC 3.51 driver to connect to mysql using odbc connectivity.I have telugu language charectors stored in the table.They are not showing properly while using the mysql odbc driver, but they are showing up properly while using the sqlserver odbc driver. Here is my connetion stri...

Delphi - Save DateTime Null to DB (ADO / MySQL)

Hi, i have a delphi form with some DB Controls on it. To represent a date I use the TJvDBDatePickerEdit (from JCL), which has a nice property ShowCheckBox := True; to allow the user to enter that no date is known (DBNull). I verify, that nulling the DatePicker works as expected by: procedure Tframe.adoQueryBeforePost(DataSet: TDat...

DSN to connectionstring?

We've got an ASP.NET website that uses a database that we want to be able to use a connectionstring to get to. We've successfully set up a DSN for connecting to this DB, but I can't seem to discover the correct magic to go with a connectionstring. Is there a straightforward way to translate the values from the DSN into a connectionstri...

How can I connect to Lotus thru ODBC using VBA?

I'm interested in setting up an Access db to run a report automatically. To save myself the trouble of going to each client computer and setting up the appropriate DSNs, I'd like to set up the ODBC connections in the VB script itself if possible. I've googled and checked this site and found some good starter code, but not enough to ma...