[prev in list] [next in list] [prev in thread] [next in thread]
List: mysql-odbc
Subject: Problems with MyODBC and ASP.NET 2.0
From: Marko Ludolph <ludi.lists () googlemail ! com>
Date: 2005-12-21 10:47:30
Message-ID: 2c3b102e0512210247s1c4ece54k70c7bb20af8c0b42 () mail ! gmail ! com
[Download RAW message or body]
Hi,
after creating my asp application (C#) with access as database, I want
to do the final step and use MySQL. But I have strange problems using
the ODBC-Connector.
Here is a small example:
The ASP-Code:
<asp:SqlDataSource
ID="SqlDataSource1"
runat="server"
ConnectionString="DRIVER={MySQL ODBC 3.51
Driver};SERVER=localhost;DATABASE=scanner;USER=root;PASSWORD=mysql;OPTION=3;"
ProviderName="System.Data.Odbc"
SelectCommand="SELECT Kit_ID FROM
scanner.kit_konfiguration WHERE Kit_ID > @ID">
<SelectParameters>
<asp:Parameter Type="int32" Name="ID" />
</SelectParameters>
</asp:SqlDataSource>
I only create a datasource with a select statement, and one parameter
(@ID). But when setting the ID within C#, the database only returns 0
rows, here is the C#-Code:
protected void Page_Load(object sender, EventArgs e)
{
SqlDataSource1.SelectParameters["ID"].DefaultValue = "0";
}
All this code works fine using access.
Software:
Latest ODBC Connector 3.51.12 and MySQL 4.1.13 on Windows XP Home
Edition SP2 + all updates available.
Could anyone help me?
Regards
Marko
--
MySQL ODBC Mailing List
For list archives: http://lists.mysql.com/myodbc
To unsubscribe: http://lists.mysql.com/myodbc?unsub=mysql-odbc@progressive-comp.com
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic