locked
Generate update, delete and insert greyed out RRS feed

  • Question

  • Dear all,

    I'm using Visual Studio beta 2005 with postgreSQL through an ODBC connection. I recently upgraded from 2003 and wanted to make new tableadapter in my dataset. The dataAdapter is created but I'm unable to auto-generate the update, delete and insert commands. The primary keys are detected and are shown bold in the Query Builder. Could someone please help me with what is going wrong?

    With kind regards,

    Paul

    Thursday, August 25, 2005 12:01 PM

Answers

  • When you create the select query remove the "public" from f.e. "public".addresses (schema name) after that you update generation goes smoothly...

    Paul
    Thursday, August 25, 2005 1:39 PM
  •  

    Dear Sarah,

    My problem was actually PostgreSQL specific. On SQL2005 this problem should not occur. 

    When you right click in your dataset you can create a new tableadapter. After you select a connection there is a button with "advanced options" there you can check if you want statements to be generated. Also the primary key must be set for the statements to be generated.

    Hope this helps,

    Cheers,

    Paul

    Thursday, January 12, 2006 12:21 PM

All replies

  • When you create the select query remove the "public" from f.e. "public".addresses (schema name) after that you update generation goes smoothly...

    Paul
    Thursday, August 25, 2005 1:39 PM
  • I have exactly the same problem when using the 'Configure Data Source' menu item in the SQLDataSource control. I am using Visual Studio 2005 and SQLServer 2005.

    How do I see my select schema? I don't see the "public" prefix anywhere.

    Thank you in advance for any help you can give.

    Sarah

     

    Thursday, January 12, 2006 8:09 AM
  •  

    Dear Sarah,

    My problem was actually PostgreSQL specific. On SQL2005 this problem should not occur. 

    When you right click in your dataset you can create a new tableadapter. After you select a connection there is a button with "advanced options" there you can check if you want statements to be generated. Also the primary key must be set for the statements to be generated.

    Hope this helps,

    Cheers,

    Paul

    Thursday, January 12, 2006 12:21 PM
  •  

    Thank you very much - it was because the primary key was not selected.

    Sarah

     

    Thursday, January 12, 2006 1:30 PM