AllExperts > Experts 
Search      

VB.NET

Volunteer
Answers to thousands of questions
 Home · More Questions · Answer Library  · Encyclopedia ·
More VB.NET Answers
Question Library

Ask a question about VB.NET
Volunteer
Experts of the Month
Expert Login

Awards

About Us
Tell friends
Link to Us
Disclaimer

 
 
 
 
About Syed Rizwan Muhammad Rizvi
Expertise
I can answers questions regarding web based and desktop based programming in VB.Net. Which can include SOAP, XML, Custom Controls, COM Interoperability etc.

Experience
Have been working in this specific area for last 2 years previously I was a VB 6 Developer with experties in other languages as well. Total 10 years of programming experience.

 
   

You are here:  Experts > Computing/Technology > Basic > VB.NET > VB.NET

Topic: VB.NET



Expert: Syed Rizwan Muhammad Rizvi
Date: 6/15/2007
Subject: VB.NET

Question
QUESTION: I face a error "Dynamic SQL generation for the UPDATE command is not Support against a SELECT command that does not return any Column information",when I Update a Dataset.My table is open in READ ONLY (in SQL Analyser).


I write Same Code for Update a dataset in another table that open in read/Write mode , Work Porperly.

Is this error is generate due READ ONLY Access?if yes then what can I do for that.

Thank U


ANSWER: can you paste the steps that you are performing so I can generate the error at my place?

---------- FOLLOW-UP ----------

QUESTION: dim ada as sqldataadaptor

dim ds as new dataset

dim drow as datarow







ada=getadaptor(SQlConn,"Select * from XYZ table") 'XYZ table is read only



ada.fill(ds)

drow=ds.tables(0).rows(0)

drow.beginedit

drow("Code")=drow("Code")+1

drow.endedit()



dim cmd as sqlcommandbuilder(ada)

if ds.haschanges=true then

ada.update(ds)'''Error generate

end if









SAME CODE WRITE FOR ANOTHER TABLE "abc"(ITS A READ/WRITE BOTH) THEN ITS RUNN SUCCESSFULLY



PLZ HELP ME


Answer
Looks like you are trying to access a readonly view, which is not returning table column info. Can you try providing sepcific column names instead of *.

If this doesnt solve the problem then i wont be able to help unless I have the database and I can run this piece of code at my end.

Regards,
Rizwan

Add to this Answer    Ask a Question



  Rate this Answer
   Was this answer helpful?
Not at allDefinitely              
   12345  

     
About Us | Advertise on This Site | User Agreement | Privacy Policy | Help
Copyright  © 2008 About, Inc. About and About.com are registered trademarks of About, Inc. The About logo is a trademark of About, Inc. All rights reserved.