Quantcast
Channel: MySQL Forums - Connector/ODBC
Viewing all 1136 articles
Browse latest View live

ORA--02070 database does not support some function in this context (1 reply)

$
0
0
We are receiving the following error message when trying to update a table in MySQL from an Oracle database link. MySQL database resides in the cloud. We can select from the tables, insert into the tables, and update without using a where clause but it updates all records.

Update table_name set submit_ready=0 where userid = 'padamp'
*
ERROR at line 1:
ORA-02070: database SAP2PORTAL does not support some function in this context

ODBC Connection Failed when using Telstra (1 reply)

$
0
0
I am trying on 2 different client PCs to connect to an external MYSQL database (different MYSQL databases and host ISPs with each Client - but both Clients use Telstra to connect to the Internet), using the standard MYSQL 5.1 Driver, and in both cases the User I specify is failing because the User that is being validated at the MYSQL end has an additional Telstra string appended.

These connections work fine from my office via an Optus connection.

e.g. I specify "MyUserID" and what gets rejected is 'MyUserID'@'client.lnk.telstra.net' - where "client" is the client's ID with Telstra.

There are no settings within the ODBC connection that I can see. The common denominator is Telstra but I have my doubts that we will get any meaningful response from them.

Any ideas?

Regards
Kevin Seerup

Error_code: 1146 on replica server (no replies)

$
0
0
I have a SQL with a linkserver with ODBC 5.3 to MySQL 5.7.

When I think a table on the master server's MySQL all right, but it does not replicate the table. If I update the table with a value I give this error:

[ERROR] Slave SQL for channel '': Error executing row event: 'Table 'db.table' doesn't exist', Error_code: 1146

Host Blocked Too Many Connections (no replies)

$
0
0
I have been using libreoffice to access my mysql database using the native connection. I decided to give ms access a try by using the odbc connector and i received and error blocked host to many connections. I do not have superuser right to the data base as its on a webserver. But i got someone to flush hosts and they say there are no connections but i still get this error. Now libreoffic gives me the error too and i cant remotely access the database. Any suggestions?

Connect to remote MySQL database. (no replies)

$
0
0
We have a DSN on machine A that points to a MySQL on machine B. We have a machine C, that we want to be able to use that DSN on machine A...but we don't want to create the DSN on machine C.

Is there a way to use the System DSN on machine A from machine C?

Or some other way to connect to the MySQL on B?

SQL Set Statements and ODBC (no replies)

$
0
0
Hello,

I have created a SQL query in MySQL workbench which uses a SET statement to update numerous parts of the query with a specific date. The statement is :

SET @MaxDate = '2016-04-30';

Whenever I run the query, all I have to do is change the month end date. I tried to use this same query in excel using an ODBC connection to my data base but get a syntax error. If I remove the Set statement in the ODBC SQL statement within excel, the query will run without the error.

I would like to be able to use an ODBC connection to pull month end information from my database by only updating the date one time in my query.

Please help.

Mysql with Visual Studio - VB.net - Connector (no replies)

$
0
0
Friends

I am in a project using Mysql 5.5.20 with vb.net 2010 with the connection drive 6.9.4.0.
Where I had to install the framework 2.0.50727.42 only though I'm getting the message below, would anyone have any idea what I would need to do to make sure the connection to the database?

The type initializer for (...) threw an exception.
MySql.Data, Version = 6.9.4.0

-> System.TypeInitializationException: The type initializer for 'PJ_NETSOL.Mod_Funcoes_MYSQL' threw an exception.

-> System.IO.FileNotFoundException: Could not load file or assembly 'MySql.Data, Version = 6.9.4.0

At PJ_NETSOL.Mod_Funcoes_MYSQL..cctor ()

ODBC connector and credentials encryption (no replies)

$
0
0
Hi

I am using the MySQL ODBC 5.1 Driver to create an ODBC DSN on a Windows machine.

I want to know if username and password are encrypted by default, or if I need to connect using SSL to achieve this.

This page (https://www.experts-exchange.com/questions/28119726/Secure-ODBC-Connection-to-Hosted-MySQL-database.html#answer39145722) seems to suggest that encryption is by default, but I haven't found any documented confirmation of that.

Thanks very much, Mike

Driver has bug when calling stored procecure using cursor. (2 replies)

$
0
0
When I call following stored procedure, driver returns invalid garbage output parameter value.
If I remove "open v_cursor" line, then it works fine.

Stored Procedure
-----------------------------------------------------------------------------
CREATE PROCEDURE `cursor_test`(out o_int int, out o_string varchar(20))
BEGIN
declare v_cursor cursor for select 2;

open v_cursor;

set o_int = 123;
set o_string = "chaeyk";
END
-----------------------------------------------------------------------------

C# code
-----------------------------------------------------------------------------
using System.Data;
using System.Data.Odbc;

...

string connectionString = "Driver={MySQL ODBC 5.3 UNICODE Driver};Server=xxxx;Port=yyyy;Database=zzzz;User = aaa; Password = bbb; Option = 4194304;";

using (OdbcConnection connection = new OdbcConnection(connectionString))
{
OdbcCommand command = new OdbcCommand("call cursor_test(?, ?)", connection);
command.Parameters.Add("o_int", SqlDbType.Int).Direction = ParameterDirection.Output;
command.Parameters.Add("o_string", SqlDbType.VarChar).Direction = ParameterDirection.Output;

connection.Open();
command.ExecuteNonQuery();
Console.WriteLine("\t{0}\t{1}", command.Parameters["o_int"].Value, command.Parameters["o_string"].Value);
}
-----------------------------------------------------------------------------

C++ code
-----------------------------------------------------------------------------
_ConnectionPtr pConnection;
pConnection.CreateInstance(__uuidof(Connection));

_bstr_t bstrConnection = "Driver={MySQL ODBC 5.3 UNICODE Driver};Server=xxxx;Port=yyyy;Database=zzzz;User = aaa; Password = bbb; Option = 4194304;";
_bstr_t bstrUser = user;
_bstr_t bstrPass = pass;

pConnection->Open(bstrConnection, bstrUser, bstrPass, adModeUnknown);
pConnection->CursorLocation = adUseClient;
pConnection->PutCommandTimeout(300);

_CommandPtr cmd;
cmd.CreateInstance(__uuidof(Command));
cmd->ActiveConnection = pConnection;

cmd->CommandType = adCmdStoredProc;
cmd->CommandText = _bstr_t(L"cursor_test");
cmd->Parameters->Append(cmd->CreateParameter(_bstr_t(L"o_int"), adInteger, adParamOutput, 4, _variant_t(_bstr_t(L"0"))));
cmd->Parameters->Append(cmd->CreateParameter(_bstr_t(L"o_string"), adVarWChar, adParamOutput, 4096, _variant_t(_bstr_t(L""))));

_variant_t vNull;
vNull.vt = VT_ERROR;
vNull.scode = DISP_E_PARAMNOTFOUND;

cmd->Execute(&vNull, &vNull, adCmdStoredProc);

_variant_t v = pCmd->Parameters->Item[_variant_t("o_int")]->Value;
_bstr_t bstr = (_bstr_t) v;
const char* str = (const char*) bstr;
printf_s("o_int=%s\n", name, str);

-----------------------------------------------------------------------------

Silent instalation for MySQL connector through commandline (no replies)

$
0
0
Hello guys,
I'm working doing some tests about MySQL, and I want to know if exists a way in order to realize an automated silent installation through commandline of MyQSL connector on a Windows machine.

Thanks in advance.

Delphi ODBC connection on Win7 X64 (no replies)

$
0
0
I have sucessfully installed ODBC 3.5.1 on my Win7 x64 machine.
I have connected and verified connectivity to the mysql database via the ODBC test, and via command line mysql command.
However, my Delphi application is failing - it is sending a connect to database with a mixed case database name.
From the ODBC log:
8e28-655c EXIT SQLDriverConnectW with return code -1 (SQL_ERROR)
[MySQL][ODBC 3.51 Driver]Access denied for user 'myuser'@'%' to database 'MyDB' (1044)
The mysql database name is all lowercase.
The same execuatable on Win7x32 does NOT fail.
.
I do not have an environment to be able to recompile the execuatable. (sad-face)!
.
So a couple of questions.
a) Is there a way to force the existing application to pass all lowercase.
b) Is there a way to force the ODBC to change the case to all lowercase.
c) Is there some setting on the server side that can allow a mixed case call to work (PS. I am not a programmer or DBA).
d) Is there a different ODBC driver that might work.

Prompt for Username/Password when connecting (no replies)

$
0
0
Hi guys,

im developing an app in Matlab where i use ODBC for connecting to a MySQL database.

Problem:The password and username is stored permanent when i set up the odbc connection (DNS, Host, etc). I want to run the app on a single windows-user for many persons.

Is there any possiblity to ask for the password and username of the odbc connection when the App gets started?

At the Moment there is no authentication when the app gets started because the password and username of the initial set up is used.

Thanks in advance!

how to set latin1_general_cs collation in ODBC connection (no replies)

$
0
0
Hi!
Does anybody knows how to set the latin1_general_cs colllation in ODBC connection? (in the Control Panel ... Data source ODBC...).

I use latin1 charset, but the default collation is latin1_swedish_ci.
I need case insensitive, without setting in the scripts of the creation for tables, procedures, etc.

Thanks.

Data Source Name in UTF-8 (no replies)

$
0
0
Does mysql support DataSourceName in UTF8? I searched document and forum and could not find any reference.

Tested using
iusql '進mysql1' username passwd
and it gives
[ISQL]ERROR: Could not SQLDriverConnect

odbc.log give this trace:
ODBC][532][1492644300.940393][SQLDriverConnectW.c][290]
Entry:
Connection = 0x2032d10
Window Hdl = (nil)
Str In = [DSN=進mysql1;UID=xxxx;PWD=xxxx][length = 35 (SQL_NTS)]
Str Out = (nil)
Str Out Max = 0
Str Out Ptr = (nil)
Completion = 0
UNICODE Using encoding ASCII 'ISO8859-1' and UNICODE 'UCS-2LE'

[ODBC][532][1492644300.943881][SQLDriverConnectW.c][699]
Exit:[SQL_ERROR]


odbc.ini setting is like this:
[進mysql1]
Driver = MySQL ODBC 5.3 Unicode Driver
Database = xxxx
Server = xxxxx
Port = xxxx
charset = utf8

How to setup SSL connection from local mysql server to vba client using ODBC (no replies)

$
0
0
Hi

I have a VBA/MS Access app which connects to a local MYSQL server (running on centos) using the Windows ODBC connector.

I want to secure this connection with the use of an SSL certificate.

I have read many how to guides and am really struggling to find a consise how to for my needs.

Can anyone help me through the process?

thanks

Pb Integer Select Mysql VB 2015 (1 reply)

$
0
0
Hi,

I'm new to MySql databases and using it with VB:

I've been surching on the net for days, and all I found is questions like mine with no suggestions that seems to work for anyone... so I'm asking again...

If I initialize Key1 = 1 delcared as integer (or int32, int16, ...) the select doesn't find anything in the table. The Pgr do not go into the loop that fills the object, but if I put Menu_Id = 1" in the query it works...

I'm trying to retrieve data from a table that has a key declared as an Integer (or any other type of integer, I've tried them all) and the select doesn't find any row. But if I put the value 1 in the select clause, it works! here is the code: (I'm new to VB with SQL querys, so trie to explain in detail, if I may ask.)

Imports MySql.Data.Entity
Imports MySql.Data.MySqlClient
Imports MySql.Data.Types

Public Class Form1
Dim Connexion As String = "Server=localhost;Database=Project_Inca;Uid=root; password=test;"

' Public ile As String
Public Function connecter()
Dim conn As MySqlConnection = New MySqlConnection
conn.ConnectionString = Connexion
conn.Open()
Return conn
End Function

Private Sub Fonds_Load(sender As Object, e As EventArgs) Handles MyBase.Load
Dim lecteur As MySqlDataReader
Dim Requete As String
Dim key1 As Integer = 1
connecter.Close()
connecter()
Requete = "select Tool_Id, Tool_Mn_1 from Menu_tools where Tool_Id = key1"
ComboBox2.Items.Add(key1.GetType)
Dim Commande As New MySqlCommand(Requete, connecter)
lecteur = Commande.ExecuteReader
Do While lecteur.Read
ComboBox2.Items.Add(lecteur.GetString("Tool_Mn_1"))
Loop
connecter.Close()
End Sub
End Class

Specified driver could not be loaded (no replies)

$
0
0
An application using ADODB to connect to a MySQL database from Excel, which was working when last used (December 2016) now fails when attempting to connect to the database. The error message is "Specified driver could not be loaded due to system error 126 (MySQL ODBC 5.3 UNICODE Driver)."

On investigating further, I see that the driver is myodbc5w.dll. I ran Dependency Walker on this and it reported two missing dlls, IEShims.dll and MSVCR120.DLL. There is a IEShims.dll in Program Files\Internet Explorer, but the other DLL seems genuinely missing though there is a file called msvcr120_clr0400.dll in System32.

I also note that my most recent Microsoft Visual C++ Redistributable is 2015 version 14.0.24215 which was apparently installed 15th Mar 2017. I did not install this explicitly, but as this is a later date than my MySQL Connector, I wonder if some incompatibility may have arisen. My myodbc5w.dll is version 5.3.7.0

I attempted a reinstall of the latest version of the MySql connector (having uninstalled the existing version), but this also failed, so I have system restored to undo any changes this may have brought about.

I am running Windows Vista 32 bit.

MySQL ODBC 5.2a Driver (no replies)

$
0
0
Hi,

We need MySQL 5.2a Driver. Please provide the Link

Regards
Prasanna.B

Access violation with BLOB columns (2 replies)

$
0
0
I have an application which uses MFC ADO ODBC and can utilize either MS SQL Server or MySQL as the database engine. It works fine with MS SQL Server.

What is happening with MySQL is an access violation in the processing for SQLSetPos when updating a table row. Specifically, I can see with the 5.3.8 ODBC Connector driver that my_realloc is being called with a buffer address of 1. This results in an attempt to access location 0xffffffe9.

Something different happens with the ODBC Connector 5.2.6, but it still results in an access violation. I am going to try going back further in archived versions of the ODBC Connector, but I am not entirely hopeful here.

The table in question has two columns defined as mediumblob and one of them is clearly the culprit here. The new allocation length being supplied to my_realloc is the length of the data in the first mediumblob as a result of the update.

I have tried bypassing this specific update and the result is simply that a later update fails for the same table. I suspect there is something questionable that I am doing in the application, but the fact that it works fine with SQL Server indicates to me that whatever is causing this problem isn't all that strange.

There is a lot of code involved with this in the application. I am probably going to try to reduce this down to a simple case to reproduce the failure that can be posted.

Fail to install MySQL ODBC Connector on HP-UX (no replies)

$
0
0
Hi, I have a problem in installing my MySQL Connector ODBC because when I enter the command:

# myodbc-installer -a -d -n "MySQL ODBC 5.1 Driver" -t "Driver=/mysql/mysql-con/mysql-connector-odbc-5.1.7-hpux11.31-ia64-64bit/lib/libmyodbc5.so"

the system shows error such as:

# /usr/lib/hpux64/dld.so: Unable to find library 'libodbc.so.1'.
Killed

FYI, I have already successfully install unixODBC onto the HP-UX. And there is 'libodbc.so.1' file inside my UnixODBC lib folder.

Can anyone suggest a solution? Thanks in advance for your reply.
Viewing all 1136 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>