navigation
a webmaster learning community
     Home    Register     Search      Help      Login    
Sponsors

Shopping Cart Software
Ecommerce software integrated into Frontpage, Dreamweaver and Golive templates. No monthly fees and available in ASP and PHP versions.

Website Templates
We also have a wide selection of Dreamweaver, Expression Web and Frontpage templates as well as webmaster tools and CSS layouts.

Frontpage website templates
Creative Website Templates for FrontPage, Dreamweaver, Flash, SwishMax

Search Forums
 

Advanced search
Recent Posts

 Todays Posts
 Most Active posts
 Posts since last visit
 My Recent Posts
 Mark posts read

Microsoft MVP

 

strange updating mysql question

 
View related threads: (in this forum | in all forums)

Logged in as: Guest
Users viewing this topic: none
Printable Version 

All Forums >> Web Development >> ASP and Database >> strange updating mysql question
Page: [1]
 
crosscreek

 

Posts: 107
Joined: 2/5/2008
Status: offline

 
strange updating mysql question - 3/8/2008 0:28:10   
I have a strange question.

I have set up a asp form to add a record to my database.

In mysql database I have

field "name" is set to TEXT
I tried to set it to varchar with Length 50, but still will not add.

The crazy thing is that I can only type in 15 letters/characters. If I go over 15 letters I get a Error message

Multiple-step OLE DB operation generated errors. Check each OLE DB status value, if available. No work was done.

Why would this be happening? I want the field to at least hold 30 to 40 characters/letters.

Very strange. Any ideas.
Spooky

 

Posts: 26597
Joined: 11/11/1998
From: Middle Earth
Status: offline

 
RE: strange updating mysql question - 3/8/2008 1:23:06   
Does this apply?

http://databases.aspfaq.com/database/what-is-this-multiple-step-ole-db-error.html

How are you inserting?

_____________________________

If you arent part of the solution, then there is good money to be made prolonging the problem

§þ:)


(in reply to crosscreek)
crosscreek

 

Posts: 107
Joined: 2/5/2008
Status: offline

 
RE: strange updating mysql question - 3/8/2008 2:01:55   
I'm using a pretty basic procedure. I am just adding a dog to the database. Once added people can upate the info.


I looked at the site you posted & I didn't see anything that was relative. Maybe the text where you add the variable at the start & don't change it.

But to test that I added 2 fields to the database

names --- varchar(50) Didn't work (added less then 15 char, but not over) same error as before

namesdog --- text (typed in 50)
[Microsoft][ODBC Driver Manager] Invalid string or buffer length


Below is the origional code

adddog.htm
<form method="POST" Action="adddog.asp">
<p><b>Add Dog:  <input type="text" name="doggy" size="50"></b></p><p> </p>
<p><input type="submit" value="Submit" name="B1"><input type="reset" value="Reset" name="B2"></p>
</form>

Adddog.asp page

<%


Dim objRS
Set objRS = Server.CreateObject("ADODB.Recordset")
objRS.Open "tbldog", myConn, , adLockOptimistic, adCmdTable

objRS.AddNew
objRS("name") = Request.form("doggy")
objRS.Update
Response.write "you have added the dog"
objRS.Close
Set objRS = Nothing
myConn.Close
Set myConn = Nothing
%>
Not much to the code...

No sure what to think about this




(in reply to Spooky)
Spooky

 

Posts: 26597
Joined: 11/11/1998
From: Middle Earth
Status: offline

 
RE: strange updating mysql question - 3/8/2008 3:29:54   
Try the 5th "IF" (AddNew/Update) and consdier the other method?

_____________________________

If you arent part of the solution, then there is good money to be made prolonging the problem

§þ:)


(in reply to crosscreek)
crosscreek

 

Posts: 107
Joined: 2/5/2008
Status: offline

 
RE: strange updating mysql question - 3/8/2008 9:51:11   

quote:

ORIGINAL: Spooky Try the 5th "IF" (AddNew/Update) and consdier the other method?


Sorry..Not quite sure what you meant by 5th and other method

(in reply to Spooky)
crosscreek

 

Posts: 107
Joined: 2/5/2008
Status: offline

 
RE: strange updating mysql question - 3/8/2008 10:36:40   
Not sure what I did, but it works now. I manually added a dog with a longer name in the database & now I am able to add dogs.

Very strange....Thanks again for your time & help!!!

It's much appreciated. I promise I have figured out alot of stuff.

(in reply to crosscreek)
Page:   [1]

All Forums >> Web Development >> ASP and Database >> strange updating mysql question
Page: [1]
Jump to: 1





New Messages No New Messages
Hot Topic w/ New Messages Hot Topic w/o New Messages
Locked w/ New Messages Locked w/o New Messages
 Post New Thread
 Reply to Message
 Post New Poll
 Submit Vote
 Delete My Own Post
 Delete My Own Thread
 Rate Posts