Ask a Question related to ASP Database, Design and Development.
-
Jeremy #1
Error 80040e14 on connecting to database
Any ideas??
Here is the error I'm getting:
<p>Microsoft OLE DB Provider for ODBC Drivers</font> <font
face="Arial" size=2>error '80040e14'</font>
<p>
<font face="Arial" size=2>[Microsoft][ODBC Microsoft Access Driver]
Unknown</font>
Here is my code:
<%@ language = "JavaScript" %>
<% var strconnection = "DSN=Products;DATABASE=Products"; %>
<head>
<script language=JavaScript>
<%
var tbl="";
var rs4 = Server.CreateObject("ADODB.Recordset");
var sql = "SELECT DISTINCT stock, Name, Manuf, Price, Note, Retail,
Image, Description FROM Products";
rs4.Open(sql,strconnection);
var n=0;
while (!rs4.EOF)
{
var stk = rs4.Fields("stock").value;
var nam = rs4.Fields("Name").value;
var man = rs4.Fields("Manuf").value;
var prc = rs4.Fields("Price").value;
var not = rs4.Fields("Note").value;
var ret = rs4.Fields("Retail").value;
var img = rs4.Fields("Image").value;
var dsc = rs4.Fields("Description").value;
{
var tbl = tbl += "<table WIDTH='700' border='0'>\n";
{
tbl += " <td WIDTH='150'>\n";
tbl += (img) ? " <DIV ALIGN='CENTER'><IMG src='images/" +
img + "' height='80'>\n" : "<DIV ALIGN='CENTER'><IMG
src='images/nf.jpg' height='80'>";
tbl += " </td>\n";
tbl += "<TD width='250'>\n";
tbl += (nam) ? "" + nam + "\n" : "";
tbl += (man) ? "" + man + "\n" : "";
tbl += " </td>\n";
tbl += "<TD width='100'>\n";
tbl += (prc) ? "" + prc + "\n" : "CALL";
tbl += " </td>\n";
tbl += "<TD width='200'>\n";
tbl += (not) ? "<p><font color='#FF0000'><strong>" + not +
"</strong></font></p>\n" : "";
tbl += (ret) ? "<p><strong>Retail Price:" + ret + "\n" : "";
tbl += " </td>\n";
tbl += " </tr><tr>\n";
tbl += (dsc) ? " <td COLSPAN='4'><p><strong><font size='" + -1 +
"'>Description: </strong>" + dsc + "</font></p></td>\n" : "";
}
tbl += "</table><hr>\n";
}
rs4.MoveNext();
n++;
}
rs4.Close();
Response.Write("document.repForm.write('" + tbl + "')")
%>
</script>
<meta http-equiv="Content-Type" content="text/html;
charset=iso-8859-1"></head>
<html>
<BODY>
<hr SIZE=4>
<table>
<td WIDTH='347' bgcolor="#0066FF"><div
align="center"><strong>Product</strong></div></td>
<td WIDTH='350' bgcolor="#0066FF"><div
align="center"><strong>Price</strong></div></td>
</table>
<%=tbl%>
</BODY>
</HTML>
Jeremy Guest
-
Error connecting to DB2 Sample database
I've just installed DB2 Personal Edition V8 and managed to get the sample database created etc. However, when I attempt to connect to it in the CF... -
800a01ad error when connecting to database in ASP.
I have developed a simple ASP/VBScript application to allow a school IT coordinator to keep tabs on what software is installed on various PCs... -
JET Database Engine error '80040e14'
I've got a query command that is checking a field name against it's value. The query is pulling from an Access 2000 DB. Here's the script: ... -
#10316 [Com]: error in connecting to MS access database
ID: 10316 Comment by: subisiva at yahoo dot com Reported By: thomasj at cs dot uidaho dot edu Status: Closed... -
Error connecting to Access database
Created new page, selected dynamic page and ASP VBscript from dynamic page list. In defining custome connection string, in connection string field,... -
Aaron Bertrand - MVP #2
Re: Error 80040e14 on connecting to database
> <% var strconnection = "DSN=Products;DATABASE=Products"; %>
Where did you get this syntax? Why are you using an ODBC DSN? Please see
[url]http://www.aspfaq.com/2126[/url]
Why are you using an explicit ADODB.Recordset? Please see> var rs4 = Server.CreateObject("ADODB.Recordset");
[url]http://www.aspfaq.com/2191[/url]
Also, by naming this object rs4, I take it you have four separate recordset
objects in this page? Why?
Why are you using DISTINCT here? Do you really have duplicates in the> var sql = "SELECT DISTINCT stock, Name, Manuf, Price, Note, Retail,
> Image, Description FROM Products";
table? Have you ever heard of a primary key? Please see
[url]http://www.aspfaq.com/2504[/url]
(I also plan to write an article on the perils of not having a primary key,
and why DISTINCT should never be necessary in a properly designed system).
--
Aaron Bertrand
SQL Server MVP
[url]http://www.aspfaq.com/[/url]
Aaron Bertrand - MVP Guest
-
Jeremy #3
Re: Error 80040e14 on connecting to database
"Aaron Bertrand - MVP" <aaron@TRASHaspfaq.com> wrote in message news:<e5ItW9RMEHA.2064@TK2MSFTNGP12.phx.gbl>...
The file structure in the ISP's Server is set up as a UNIX server>> > <% var strconnection = "DSN=Products;DATABASE=Products"; %>
> Where did you get this syntax? Why are you using an ODBC DSN? Please see
> [url]http://www.aspfaq.com/2126[/url]
would be (even though it is a windows server) thus the physical path
option wasn't working.
This code was truncated...>>> > var rs4 = Server.CreateObject("ADODB.Recordset");
> Why are you using an explicit ADODB.Recordset? Please see
> [url]http://www.aspfaq.com/2191[/url]
>
> Also, by naming this object rs4, I take it you have four separate recordset
> objects in this page? Why?
>
I wanted to avoid any duplicates in the table>> > var sql = "SELECT DISTINCT stock, Name, Manuf, Price, Note, Retail,
> > Image, Description FROM Products";
> Why are you using DISTINCT here? Do you really have duplicates in the
> table? Have you ever heard of a primary key? Please see
> [url]http://www.aspfaq.com/2504[/url]
>
Still getting the error though even if I make these changes. Does> (I also plan to write an article on the perils of not having a primary key,
> and why DISTINCT should never be necessary in a properly designed system).
anyone know the reserved words...I think the 'NAME' table header is
reserved so I need to change that, but any others?
Thanks!
Jeremy
Jeremy Guest
-
Aaron Bertrand - MVP #4
Re: Error 80040e14 on connecting to database
> The file structure in the ISP's Server is set up as a UNIX server
What on earth are you talking about? "as a UNIX server would be"?> would be (even though it is a windows server) thus the physical path
> option wasn't working.
My question was more along the lines of, why are there duplicates in the> I wanted to avoid any duplicates in the table
table in the first place? (AGain, have you heard of a primary key?)
WHAT changes?> Still getting the error though even if I make these changes.
[url]http://www.aspfaq.com/2080[/url]> Does anyone know the reserved words...
--
Aaron Bertrand
SQL Server MVP
[url]http://www.aspfaq.com/[/url]
Aaron Bertrand - MVP Guest
-
Phillip Windell #5
Re: Error 80040e14 on connecting to database
"Jeremy" <jeremy_zifchock@yahoo.com> wrote in message
news:f9d85033.0405040541.6f48b2c5@posting.google.c om...The physical path will still work,...you just have to find out what it is.> The file structure in the ISP's Server is set up as a UNIX server
> would be (even though it is a windows server) thus the physical path
> option wasn't working.
Since it is an ISP's server it is most likely that you MDB file is within
the web path.
Create a simple ASP page containing this:
Response.write Application("APPL_PHYSICAL_PATH") & <br>
FTP it to the ISP's server where your site is.
Then go to it in your browser and it will show the path on the server the
Website is located in.
The folder the MDB is in and the file itself must have Read/Write
Permissions for the local "IUSR_<servername>" user account set in the NTFS
permissions. There is nothing that can be "UNIX'ized" about that,...those
permission must be set.
--
Phillip Windell [MCP, MVP, CCNA]
[url]www.wandtv.com[/url]
Phillip Windell Guest
-
Phillip Windell #6
Re: Error 80040e14 on connecting to database
You can grap an ASP file I have that will give you that and other
information about a server when you FTP it to a server and open it with a
browser.
You can get it at [url]http://209.16.209.141/debug.zip[/url]
--
Phillip Windell [MCP, MVP, CCNA]
[url]www.wandtv.com[/url]
"Phillip Windell" <@.> wrote in message
news:eGei5nfMEHA.1608@TK2MSFTNGP12.phx.gbl...> "Jeremy" <jeremy_zifchock@yahoo.com> wrote in message
> news:f9d85033.0405040541.6f48b2c5@posting.google.c om...>> > The file structure in the ISP's Server is set up as a UNIX server
> > would be (even though it is a windows server) thus the physical path
> > option wasn't working.
> The physical path will still work,...you just have to find out what it is.
> Since it is an ISP's server it is most likely that you MDB file is within
> the web path.
>
> Create a simple ASP page containing this:
>
> Response.write Application("APPL_PHYSICAL_PATH") & <br>
>
> FTP it to the ISP's server where your site is.
> Then go to it in your browser and it will show the path on the server the
> Website is located in.
>
> The folder the MDB is in and the file itself must have Read/Write
> Permissions for the local "IUSR_<servername>" user account set in the NTFS
> permissions. There is nothing that can be "UNIX'ized" about that,...those
> permission must be set.
>
> --
>
> Phillip Windell [MCP, MVP, CCNA]
> [url]www.wandtv.com[/url]
>
>
Phillip Windell Guest



Reply With Quote

