Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

Can't update SQL-View data in MS Access

Posted on 2007-11-22
7
Medium Priority
?
1,389 Views
Last Modified: 2012-06-21
I created a view on sql-Server 2005 and linked it into MS Access 2003.
On SQL-Server I'm able to edit the data using the same user which is not able to edit the view in MS Access.
The user has rights and the view contains the primary key and there is no computed column.
Any idea?
Chris
0
Comment
Question by:chriswies
[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
  • 2
7 Comments
 
LVL 9

Expert Comment

by:auke_t
ID: 20334502
Is there an error message?
You can use the profiler to watch what sql statement is send to the server. Probably acces doesn't include the right key information, but I can't be sure without the profilerinfo.
0
 

Author Comment

by:chriswies
ID: 20334526
No, no message, just the beep.
Please help me out, how do I use the profiler. I'm pretty new with SQL-Server.
Chris
0
 
LVL 9

Expert Comment

by:auke_t
ID: 20334541
In sql server start the profiler (it's under the tools menu)

then start a new trace

If noone else is using the server you can just run the trace, if not, then goto the events selection tab and use the column filters to filter out your sql statements

Then try to edit the data and see what command is send to the server
0
Ransomware-A Revenue Bonanza for Service Providers

Ransomware – malware that gets on your customers’ computers, encrypts their data, and extorts a hefty ransom for the decryption keys – is a surging new threat.  The purpose of this eBook is to educate the reader about ransomware attacks.

 

Author Comment

by:chriswies
ID: 20334960
oh interesting,

that is the result:

exec sp_executesql N'SELECT "FragenID" ,"fiPrüfung" ,"fiPrüffeld" ,"PF" ,"Sort" ,"Frage" ,"FrageSub" ,"Datenquelle" ,"Datentyp" ,"Einschränkung" ,"Zahlenformat" ,"Eingabemeldung" ,"FrageDefault" ,"FrageDefaultMuss" ,"Kommentar" ,"Material" ,"FrageSAW" ,"FrageBearbeitungshinweis" ,"FrageHHST" ,"replAvg"  FROM "dbo"."vw_Fragen" WHERE ( @P1 = "fiPrüffeld" ) ORDER BY "dbo"."vw_Fragen"."fiPrüffeld" ,"dbo"."vw_Fragen"."Sort"  ',N'@P1 uniqueidentifier','5E710000-2F28-5E71-1CDE-130048A41F00'

In the Access-Form I just have "select * from vw_Fragen ORDER BY fiPrüffeld, Sort;" entered.
Does this help?
Chris
0
 

Accepted Solution

by:
chriswies earned 0 total points
ID: 20344195
OK, got it.
I had to create an index on the view in !MS Access! to tell Access that this view has an unique id!
something like
CREATE UNIQUE INDEX ix_vw_Auswertungsfragen ON vw_Auswertungsfragen(idAuswertungFeld)

thanks
Chris
0
 
LVL 1

Expert Comment

by:Computer101
ID: 20378518
Closed, 500 points refunded.
Computer101
EE Admin
0

Featured Post

The Eight Noble Truths of Backup and Recovery

How can IT departments tackle the challenges of a Big Data world? This white paper provides a roadmap to success and helps companies ensure that all their data is safe and secure, no matter if it resides on-premise with physical or virtual machines or in the cloud.

Question has a verified solution.

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

A Stored Procedure in Microsoft SQL Server is a powerful feature that it can be used to execute the Data Manipulation Language (DML) or Data Definition Language (DDL). Depending on business requirements, a single Stored Procedure can return differe…
Ready to get certified? Check out some courses that help you prepare for third-party exams.
With Microsoft Access, learn how to specify relationships between tables and set various options on the relationship. Add the tables: Create the relationship: Decide if you’re going to set referential integrity: Decide if you want cascade upda…
Do you want to know how to make a graph with Microsoft Access? First, create a query with the data for the chart. Then make a blank form and add a chart control. This video also shows how to change what data is displayed on the graph as well as form…

722 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