Need Help
am 31.03.2006 08:49:29 von bhv
hello everybody. i am new to MySQL and want to build some asp pages
providing search facility where search result displays from database. i
have successfully created database in MySQL 5.0, but i can't show them
in asp pages. the browser gives me following error:
Error Type:
Microsoft OLE DB Provider for ODBC Drivers (0x80004005)
[MySQL][ODBC 3.51 Driver]Access denied for user: 'a@localhost' (Using
password: YES)
list.asp, line 9
i have used connection strings. the file i have included in aps page is
db.inc as follows:
<%
dim dbDriver
dim dbDatabase
dim dbUser
dim dbPass
dbDriver = "{MySQL ODBC 3.51 Driver}"
dbDatabase = "bhv"
dbUser = "a"
dbPassword = "a"
%>
where as the file i used to show data is list.asp as follows:
<%@LANGUAGE="VBSCRIPT"%>
<%
dim adoConn
set adoConn = Server.CreateObject("ADODB.Connection")
adoConn.Open "Driver=" & dbDriver & "; SERVER=localhost; Database=" &
dbDatabase & "; Uid=" & dbUser & ";Pwd=" & dbPassword & ";OPTION=3;"
if adoConn.errors.count = 0 then
response.write "Connected Successfully!"
end if
%>
welcome
pl. help me
Re: Need Help
am 31.03.2006 18:33:15 von avidfan
bhv wrote:
> hello everybody. i am new to MySQL and want to build some asp pages
> providing search facility where search result displays from database. i
> have successfully created database in MySQL 5.0, but i can't show them
> in asp pages. the browser gives me following error:
> Error Type:
> Microsoft OLE DB Provider for ODBC Drivers (0x80004005)
> [MySQL][ODBC 3.51 Driver]Access denied for user: 'a@localhost' (Using
> password: YES)
> list.asp, line 9
> i have used connection strings. the file i have included in aps page is
> db.inc as follows:
> <%
> dim dbDriver
> dim dbDatabase
> dim dbUser
> dim dbPass
> dbDriver = "{MySQL ODBC 3.51 Driver}"
> dbDatabase = "bhv"
> dbUser = "a"
> dbPassword = "a"
> %>
> where as the file i used to show data is list.asp as follows:
> <%@LANGUAGE="VBSCRIPT"%>
>
> <%
> dim adoConn
> set adoConn = Server.CreateObject("ADODB.Connection")
> adoConn.Open "Driver=" & dbDriver & "; SERVER=localhost; Database=" &
> dbDatabase & "; Uid=" & dbUser & ";Pwd=" & dbPassword & ";OPTION=3;"
> if adoConn.errors.count = 0 then
> response.write "Connected Successfully!"
> end if
> %>
>
>
> welcome
>
>
>
>
>
>
>
>
> pl. help me
make sure you created the username/passwd correctly..
how did you create the user and did you make sure you granted that user
access to the database and tables?
connect to the database and
select host,user from mysql.user;
Re: Need Help
am 01.04.2006 13:10:37 von bhv
thank u very much for quick help. i had not createuser. during
installation when it asked me suername and p/w i had entered "a" and
trying to connect with this itself. is this proper way or i am doing
wrong???? now i am trying to create user as per ur suggestion i have
downlod some files and going thru them.
thanks