Solved

Microsoft JET Database Engine error '80004005'

Posted on 2001-07-19
12
263 Views
Last Modified: 2007-12-19
When I want to insert a record in the access database, available online.  I got following message.

"Microsoft JET Database Engine error '80004005'
Operation must use an updateable query"

The code, i m using is as follows...

<%
set conn=Server.Createobject("ADODB.Connection")
conn.Provider="Microsoft.jet.OLEDB.4.0"
conn.open Server.MapPath("\")&"\test.mdb"
conn.execute("insert into newsletters values('test','test')")
conn.close
set conn=nothing
%>

This works very well on local configurations.  But problem is with the database available on my ISP's web server.
But when i wanna retrieve any record from the database it is accebile, but the problem is with insertion only.
0
Comment
Question by:helloaamir
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 3
  • 2
  • +4
12 Comments
 
LVL 7

Expert Comment

by:weesiong
ID: 6297646
helloaamir,

conn.execute("insert into newsletters (yourfieldname, yourfieldname) values('test','test')")

Regards,
Wee Siong
0
 
LVL 1

Expert Comment

by:zeheb
ID: 6297689
I'm not sure it will solve your problem but it probably worth to try:

if for instance you have 2 field in your database
named "field1" and "field2" and you wish to assign the value "Field1 Value" to field1 and "Field2 Value" to field2
that your query may look like this:

INSERT INTO newletters(field1, field2) VALUES('Field1 Value', 'Field2 Value');

I hope it was helpfull -)

zeheb
0
 
LVL 1

Expert Comment

by:zeheb
ID: 6297702
I'm not sure it will solve your problem but it probably worth to try:

if for instance you have 2 field in your database
named "field1" and "field2" and you wish to assign the value "Field1 Value" to field1 and "Field2 Value" to field2
that your query may look like this:

INSERT INTO newletters(field1, field2) VALUES('Field1 Value', 'Field2 Value');

I hope it was helpfull -)

zeheb
0
[Live Webinar] The Cloud Skills Gap

As Cloud technologies come of age, business leaders grapple with the impact it has on their team's skills and the gap associated with the use of a cloud platform.

Join experts from 451 Research and Concerto Cloud Services on July 27th where we will examine fact and fiction.

 

Expert Comment

by:systemop
ID: 6297706
Try to use this


<%
db = Server.MapPath("databasepath/test.mdb")
conn2 = "DRIVER={Microsoft Access Driver (*.mdb)};DBQ=" &db
set conn=Server.Createobject("ADODB.Connection")
conn.execute("insert into newsletters values('test','test')")
conn.close
set conn=nothing
%>


SyS...
0
 
LVL 1

Expert Comment

by:zeheb
ID: 6297707
Opps I accidently post my commant twice
Sorry
0
 
LVL 14

Expert Comment

by:puranik_p
ID: 6297714
your query is fine.
problem is with your newletter table.
just check it's structure.
is it bound by some relationships?
better still, post the structure.
0
 
LVL 20

Expert Comment

by:Silvers5
ID: 6297944
Everything is fine.. this is a permission issue.. contact your isp administrator and tell him to grant the IUSR write/change permission on the database..
0
 
LVL 2

Expert Comment

by:DirkVe
ID: 6297951
Try to add other data as "test", "test".

Maybe you have defined some Primary Keys in your database, and then you tried to add (via an insert) these values again which fails of course, since primary keys are unique it doesn't accept this.

If this is the problem, tell us and we provide some solutions for that also.
0
 

Author Comment

by:helloaamir
ID: 6298059
Thanks for replying on my question, but just see that i m saying that its working well on my local configurations. It means there isn't any problem with primary key, permissions or with the query.
Zeheb and weesiong as for as i think As i have 2 fields in the database so i dont need to write the names of fields.
0
 
LVL 20

Expert Comment

by:Silvers5
ID: 6298222
Hello.. operation must be an updatable query this error is given when the database is only read only! when you upkloaded the mdb to the isp it inherited the permissions from its parent directory that are by default READ only!!! stop turning in around..
0
 
LVL 20

Accepted Solution

by:
Silvers5 earned 80 total points
ID: 6298227
...this is why you can only read but not write! permissions on your local server are not sent to the ISP web server.. (otherwise all the web servers will be hacked..
0
 

Author Comment

by:helloaamir
ID: 6298405
Thanks Silvers5, U got the point in my question, other were only telling me about the quieries...
Now the problem is solved.
0

Featured Post

[Live Webinar] The Cloud Skills Gap

As Cloud technologies come of age, business leaders grapple with the impact it has on their team's skills and the gap associated with the use of a cloud platform.

Join experts from 451 Research and Concerto Cloud Services on July 27th where we will examine fact and fiction.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I recently decide that I needed a way to make my pages scream on the net.   While searching around how I can accomplish this I stumbled across a great article that stated "minimize the server requests." I got to thinking, hey, I use more than one…
This demonstration started out as a follow up to some recently posted questions on the subject of logging in: http://www.experts-exchange.com/Programming/Languages/Scripting/JavaScript/Q_28634665.html and http://www.experts-exchange.com/Programming/…
There's a multitude of different network monitoring solutions out there, and you're probably wondering what makes NetCrunch so special. It's completely agentless, but does let you create an agent, if you desire. It offers powerful scalability …
If you’ve ever visited a web page and noticed a cool font that you really liked the look of, but couldn’t figure out which font it was so that you could use it for your own work, then this video is for you! In this Micro Tutorial, you'll learn yo…

635 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question