PC Review


Reply
Thread Tools Rate Thread

Delete Record

 
 
Graham
Guest
Posts: n/a
 
      30th Jul 2005
I am a little confused with the following error code. I only have two
fields, firstname and lastname, which are both complete. Can anyone help
please/

Database Results Error
Description: [Microsoft][ODBC Microsoft Access Driver] Too few parameters.
Expected 2.
Number: -2147217904 (0x80040E10)
Source: Microsoft OLE DB Provider for ODBC Drivers

One or more form fields were empty. You should provide default values for
all form fields that are used in the query

regards


Graham
30/7


 
Reply With Quote
 
 
 
 
Stefan B Rusynko
Guest
Posts: n/a
 
      30th Jul 2005
Are those the only 2 fields in the Access Table

If so then there is an error in the way you are passing the 2 field values (incorrect delimiters)
- post a snipped of your code

--

_____________________________________________
SBR @ ENJOY (-: [ Microsoft MVP - FrontPage ]
"Warning - Using the F1 Key will not break anything!" (-;
To find the best Newsgroup for FrontPage support see:
http://www.net-sites.com/sitebuilder/newsgroups.asp
_____________________________________________


"Graham" <(E-Mail Removed)> wrote in message news:em%(E-Mail Removed)...
|I am a little confused with the following error code. I only have two
| fields, firstname and lastname, which are both complete. Can anyone help
| please/
|
| Database Results Error
| Description: [Microsoft][ODBC Microsoft Access Driver] Too few parameters.
| Expected 2.
| Number: -2147217904 (0x80040E10)
| Source: Microsoft OLE DB Provider for ODBC Drivers
|
| One or more form fields were empty. You should provide default values for
| all form fields that are used in the query
|
| regards
|
|
| Graham
| 30/7
|
|


 
Reply With Quote
 
Graham
Guest
Posts: n/a
 
      1st Aug 2005
There is also an email address field and a timestamp field.

Here is the code for the delete record form: Please excuse size of snippet
as I am unfamiliar with it This is a .htm file

<html>

<head>
<meta http-equiv="Content-Language" content="en-us">
<meta http-equiv="Content-Type" content="text/html; charset=windows-1252">
<meta name="GENERATOR" content="Microsoft FrontPage 4.0">
<meta name="ProgId" content="FrontPage.Editor.Document">
<title>New Page 2</title>
</head>

<body bgcolor="#003366" text="#FFFFFF">

<p>&nbsp;</p>
<p>&nbsp;</p>
<p>&nbsp;</p>
<p>&nbsp;</p>
<form method="POST" action="deleterecord.asp">
<p>First Name: <input type="text" name="firstname" size="20"></p>
<p>Last Name :<input type="text" name="lastname" size="20"></p>
<p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </p>
<p>&nbsp;</p>
<p><input type="submit" value="Submit" name="B1"><input type="reset"
value="Reset" name="B2"></p>
</form>

</body>

</html>

Do you wish to see the deleterecord.asp file as well?

thanks Graham



"Stefan B Rusynko" <(E-Mail Removed)> wrote in message
news:(E-Mail Removed)...
> Are those the only 2 fields in the Access Table
>
> If so then there is an error in the way you are passing the 2 field values

(incorrect delimiters)
> - post a snipped of your code
>
> --
>
> _____________________________________________
> SBR @ ENJOY (-: [ Microsoft MVP - FrontPage ]
> "Warning - Using the F1 Key will not break anything!" (-;
> To find the best Newsgroup for FrontPage support see:
> http://www.net-sites.com/sitebuilder/newsgroups.asp
> _____________________________________________
>
>
> "Graham" <(E-Mail Removed)> wrote in message

news:em%(E-Mail Removed)...
> |I am a little confused with the following error code. I only have two
> | fields, firstname and lastname, which are both complete. Can anyone help
> | please/
> |
> | Database Results Error
> | Description: [Microsoft][ODBC Microsoft Access Driver] Too few

parameters.
> | Expected 2.
> | Number: -2147217904 (0x80040E10)
> | Source: Microsoft OLE DB Provider for ODBC Drivers
> |
> | One or more form fields were empty. You should provide default values

for
> | all form fields that are used in the query
> |
> | regards
> |
> |
> | Graham
> | 30/7
> |
> |
>
>



 
Reply With Quote
 
Stefan B Rusynko
Guest
Posts: n/a
 
      1st Aug 2005
Yes
The ASP code w/ deleting the record is the one you are getting an error on, so your form html is not relevant



--

_____________________________________________
SBR @ ENJOY (-: [ Microsoft MVP - FrontPage ]
"Warning - Using the F1 Key will not break anything!" (-;
To find the best Newsgroup for FrontPage support see:
http://www.net-sites.com/sitebuilder/newsgroups.asp
_____________________________________________


"Graham" <(E-Mail Removed)> wrote in message news:%(E-Mail Removed)...
| There is also an email address field and a timestamp field.
|
| Here is the code for the delete record form: Please excuse size of snippet
| as I am unfamiliar with it This is a .htm file
|
| <html>
|
| <head>
| <meta http-equiv="Content-Language" content="en-us">
| <meta http-equiv="Content-Type" content="text/html; charset=windows-1252">
| <meta name="GENERATOR" content="Microsoft FrontPage 4.0">
| <meta name="ProgId" content="FrontPage.Editor.Document">
| <title>New Page 2</title>
| </head>
|
| <body bgcolor="#003366" text="#FFFFFF">
|
| <p>&nbsp;</p>
| <p>&nbsp;</p>
| <p>&nbsp;</p>
| <p>&nbsp;</p>
| <form method="POST" action="deleterecord.asp">
| <p>First Name: <input type="text" name="firstname" size="20"></p>
| <p>Last Name :<input type="text" name="lastname" size="20"></p>
| <p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </p>
| <p>&nbsp;</p>
| <p><input type="submit" value="Submit" name="B1"><input type="reset"
| value="Reset" name="B2"></p>
| </form>
|
| </body>
|
| </html>
|
| Do you wish to see the deleterecord.asp file as well?
|
| thanks Graham
|
|
|
| "Stefan B Rusynko" <(E-Mail Removed)> wrote in message
| news:(E-Mail Removed)...
| > Are those the only 2 fields in the Access Table
| >
| > If so then there is an error in the way you are passing the 2 field values
| (incorrect delimiters)
| > - post a snipped of your code
| >
| > --
| >
| > _____________________________________________
| > SBR @ ENJOY (-: [ Microsoft MVP - FrontPage ]
| > "Warning - Using the F1 Key will not break anything!" (-;
| > To find the best Newsgroup for FrontPage support see:
| > http://www.net-sites.com/sitebuilder/newsgroups.asp
| > _____________________________________________
| >
| >
| > "Graham" <(E-Mail Removed)> wrote in message
| news:em%(E-Mail Removed)...
| > |I am a little confused with the following error code. I only have two
| > | fields, firstname and lastname, which are both complete. Can anyone help
| > | please/
| > |
| > | Database Results Error
| > | Description: [Microsoft][ODBC Microsoft Access Driver] Too few
| parameters.
| > | Expected 2.
| > | Number: -2147217904 (0x80040E10)
| > | Source: Microsoft OLE DB Provider for ODBC Drivers
| > |
| > | One or more form fields were empty. You should provide default values
| for
| > | all form fields that are used in the query
| > |
| > | regards
| > |
| > |
| > | Graham
| > | 30/7
| > |
| > |
| >
| >
|
|


 
Reply With Quote
 
Graham
Guest
Posts: n/a
 
      1st Aug 2005
Here is the deleterecord.asp code:
Is it noteworthy that the statements are repeated. In Frontpage, the first
are "greyed" out, the second are in "bold"?


thanks again

Graham
1/8
<html>

<head>
<meta http-equiv="Content-Type" content="text/html; charset=windows-1252">
<meta name="GENERATOR" content="Microsoft FrontPage 4.0">
<meta name="ProgId" content="FrontPage.Editor.Document">
<title>New Page 1</title>
</head>

<body bgcolor="#003366" text="#FFFFFF">

<table width="100%" border="1">
<thead>
</thead>
<tbody>
<!--webbot bot="DatabaseRegionStart" startspan s-columnnames
s-columntypes
s-dataconnection="2008entry" b-tableformat="TRUE" b-menuformat="FALSE"
s-menuchoice s-menuvalue b-tableborder="TRUE" b-tableexpand="TRUE"
b-tableheader="TRUE" b-listlabels="TRUE" b-listseparator="TRUE"
i-ListFormat="0" b-makeform="FALSE" s-recordsource s-displaycolumns
s-criteria s-order
s-sql="DELETE DISTINCTROW firstname&lt;br&gt; FROM
Results&lt;br&gt; WHERE (firstname='::Contact_firstName::')&lt;br&gt;
AND (lastname='::Contact_LastName::') &lt;br&gt;"
b-procedure="FALSE" clientside SuggestedExt="asp"
s-DefaultFields="Contact_firstName=&amp;Contact_LastName="
s-NoRecordsFound="No records returned." i-MaxRecords="256"
i-GroupSize="0"
BOTID="0" u-dblib="_fpclass/fpdblib.inc"
u-dbrgn1="_fpclass/fpdbrgn1.inc"
u-dbrgn2="_fpclass/fpdbrgn2.inc" tag="TBODY"
local_preview="&lt;tr&gt;&lt;td colspan=64 bgcolor=&quot;#FFFF00&quot;
align=&quot;left&quot; width=&quot;100%&quot;&gt;&lt;font
color=&quot;#000000&quot;&gt;Database Results regions will not preview
unless this page is fetched from a Web server with a web browser. The
following table row will repeat once for every record returned by the
query.&lt;/font&gt;&lt;/td&gt;&lt;/tr&gt;"
preview="&lt;tr&gt;&lt;td colspan=64 bgcolor=&quot;#FFFF00&quot;
align=&quot;left&quot; width=&quot;100%&quot;&gt;&lt;font
color=&quot;#000000&quot;&gt;This is the start of a Database Results region.
The page must be fetched from a web server with a web browser to display
correctly; the current web is stored on your local disk or
network.&lt;/font&gt;&lt;/td&gt;&lt;/tr&gt;" --><!--#include
file="_fpclass/fpdblib.inc"-->
<%
fp_sQry="DELETE DISTINCTROW firstname FROM Results WHERE
(firstname='::Contact_firstName::') AND
(lastname='::Contact_LastName::') "
fp_sDefault="Contact_firstName=&Contact_LastName="
fp_sNoRecords="<tr><td colspan=16 align=left width=""100%"">No records
returned.</td></tr>"
fp_sDataConn="2008entry"
fp_iMaxRecords=256
fp_iCommandType=1
fp_iPageSize=0
fp_fTableFormat=True
fp_fMenuFormat=False
fp_sMenuChoice=""
fp_sMenuValue=""
fp_iDisplayCols=16
fp_fCustomQuery=True
BOTID=0
fp_iRegion=BOTID
%>
<!--#include file="_fpclass/fpdbrgn1.inc"-->
<!--webbot bot="DatabaseRegionStart" i-CheckSum="30613" endspan -->
<!--webbot bot="DatabaseRegionEnd" startspan b-tableformat="TRUE"
b-menuformat="FALSE" u-dbrgn2="_fpclass/fpdbrgn2.inc" i-groupsize="0"
clientside tag="TBODY"
local_preview="&lt;tr&gt;&lt;td colspan=64 bgcolor=&quot;#FFFF00&quot;
align=&quot;left&quot; width=&quot;100%&quot;&gt;&lt;font
color=&quot;#000000&quot;&gt;This is the end of a Database Results
region.&lt;/font&gt;&lt;/td&gt;&lt;/tr&gt;"
preview="&lt;tr&gt;&lt;td colspan=64 bgcolor=&quot;#FFFF00&quot;
align=&quot;left&quot; width=&quot;100%&quot;&gt;&lt;font
color=&quot;#000000&quot;&gt;This is the end of a Database Results
region.&lt;/font&gt;&lt;/td&gt;&lt;/tr&gt;" --><!--#include
file="_fpclass/fpdbrgn2.inc"-->
<!--webbot bot="DatabaseRegionEnd" i-CheckSum="62730" endspan -->
</tbody>
</table>

<table width="100%" border="1">
<thead>
</thead>
</table>

</body>

</html>

"Stefan B Rusynko" <(E-Mail Removed)> wrote in message
news:#(E-Mail Removed)...
> Yes
> The ASP code w/ deleting the record is the one you are getting an error

on, so your form html is not relevant
>
>
>
> --
>
> _____________________________________________
> SBR @ ENJOY (-: [ Microsoft MVP - FrontPage ]
> "Warning - Using the F1 Key will not break anything!" (-;
> To find the best Newsgroup for FrontPage support see:
> http://www.net-sites.com/sitebuilder/newsgroups.asp
> _____________________________________________
>
>
> "Graham" <(E-Mail Removed)> wrote in message

news:%(E-Mail Removed)...
> | There is also an email address field and a timestamp field.
> |
> | Here is the code for the delete record form: Please excuse size of

snippet
> | as I am unfamiliar with it This is a .htm file
> |
> | <html>
> |
> | <head>
> | <meta http-equiv="Content-Language" content="en-us">
> | <meta http-equiv="Content-Type" content="text/html;

charset=windows-1252">
> | <meta name="GENERATOR" content="Microsoft FrontPage 4.0">
> | <meta name="ProgId" content="FrontPage.Editor.Document">
> | <title>New Page 2</title>
> | </head>
> |
> | <body bgcolor="#003366" text="#FFFFFF">
> |
> | <p>&nbsp;</p>
> | <p>&nbsp;</p>
> | <p>&nbsp;</p>
> | <p>&nbsp;</p>
> | <form method="POST" action="deleterecord.asp">
> | <p>First Name: <input type="text" name="firstname" size="20"></p>
> | <p>Last Name :<input type="text" name="lastname" size="20"></p>
> | <p>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </p>
> | <p>&nbsp;</p>
> | <p><input type="submit" value="Submit" name="B1"><input type="reset"
> | value="Reset" name="B2"></p>
> | </form>
> |
> | </body>
> |
> | </html>
> |
> | Do you wish to see the deleterecord.asp file as well?
> |
> | thanks Graham
> |
> |
> |
> | "Stefan B Rusynko" <(E-Mail Removed)> wrote in message
> | news:(E-Mail Removed)...
> | > Are those the only 2 fields in the Access Table
> | >
> | > If so then there is an error in the way you are passing the 2 field

values
> | (incorrect delimiters)
> | > - post a snipped of your code
> | >
> | > --
> | >
> | > _____________________________________________
> | > SBR @ ENJOY (-: [ Microsoft MVP - FrontPage ]
> | > "Warning - Using the F1 Key will not break anything!" (-;
> | > To find the best Newsgroup for FrontPage support see:
> | > http://www.net-sites.com/sitebuilder/newsgroups.asp
> | > _____________________________________________
> | >
> | >
> | > "Graham" <(E-Mail Removed)> wrote in message
> | news:em%(E-Mail Removed)...
> | > |I am a little confused with the following error code. I only have two
> | > | fields, firstname and lastname, which are both complete. Can anyone

help
> | > | please/
> | > |
> | > | Database Results Error
> | > | Description: [Microsoft][ODBC Microsoft Access Driver] Too few
> | parameters.
> | > | Expected 2.
> | > | Number: -2147217904 (0x80040E10)
> | > | Source: Microsoft OLE DB Provider for ODBC Drivers
> | > |
> | > | One or more form fields were empty. You should provide default

values
> | for
> | > | all form fields that are used in the query
> | > |
> | > | regards
> | > |
> | > |
> | > | Graham
> | > | 30/7
> | > |
> | > |
> | >
> | >
> |
> |
>
>



 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Prevent Subform from saving record or delete record when moving tomain form RussCRM Microsoft Access Form Coding 0 3rd Apr 2008 07:26 PM
Re: Add / Delete record from table - How to reposition selected record in datagridview??? Cor Ligthert[MVP] Microsoft VB .NET 0 31st Mar 2008 05:26 AM
How to delete a SQL Server record (descending from another record of the same table) with a C# application polocar Microsoft C# .NET 6 23rd Jul 2006 03:20 AM
Upon delete record, conditional delete record from another table =?Utf-8?B?UmljaDEyMzQ=?= Microsoft Access 6 14th Oct 2005 02:48 PM
Delete Button shows previous record before current record is delet =?Utf-8?B?UmljaDEyMzQ=?= Microsoft Access Forms 8 10th Oct 2005 01:15 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 03:17 AM.