SQL Primary Key Issue - InfoPath Dev
in

InfoPath Dev

SQL Primary Key Issue

Last post 02-25-2010 09:50 AM by oldradio99. 2 replies.
Page 1 of 1 (3 items)
Sort Posts: Previous Next
  • 02-24-2010 11:43 AM

    SQL Primary Key Issue

    I think something like this has been addressed before but I cant find it in the history.

    I have a form connected to a SQL table and as we all know, the table must have a unique Primary Key to allow the submit function.

    My form collects data, submits via email to a manager and upon approval, writes to the SQL table.  Sound simple?  Not!

    The initial view rejects because there is no data in the Primary Key and IP/SQL set that as required field.

     Do I just put in a dummy temporary number as a default value?  But if I do that, how do I remove it so that the SQL table can set a truly unique ID?

    Have I confused everyone?  I know I am.

    Thanks

    Thank you for your Help.

    Art
  • 02-24-2010 02:57 PM In reply to

    Interesting! Perhaps you could submit via rules? Then, if the form is approved, the first rule would be to clear the dummy number out of the ID field, the next would submit to the SQL data connection, etc?

    Hilary Stoupa

  • 02-25-2010 09:50 AM In reply to

    I found the answer digging through some of my older forms.

    In the new table I had not set the Primary Key as a unique identifier.  Therefore it was showing as required.

    By making that change in the table, the form now works as it should.

     

    Thank you for your Help.

    Art
Page 1 of 1 (3 items)
Copyright © 2003-2019 Qdabra Software. All rights reserved.
View our Terms of Use.