<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="https://www.infopathdev.com:443/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>Newbie Questions</title><link>https://www.infopathdev.com:443/forums/39.aspx</link><description>New to InfoPath? Search to see if your question has already been answered. If it has not, then ask it here or the appropriate topic forum.</description><dc:language>en</dc:language><generator>CommunityServer 2007 SP3 (Build: 31118.962)</generator><item><title>Re: Checking input against DB for duplicates</title><link>https://www.infopathdev.com:443/forums/thread/3565.aspx</link><pubDate>Thu, 30 Nov 2006 00:57:46 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:3565</guid><dc:creator>Patrick Halstead</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/3565.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=39&amp;PostID=3565</wfw:commentRss><description>You're going to have to write some code that queries the DB and checks for the value. We are about to release our new Database Accelerator Suite (Basic version is FREE) which you could use to do this *WITHOUT HAVING TO WRITE CODE*. The suite will go live in 3-4 weeks. In the meantime, please send me e-mail if you'd like to install a beta version. &lt;br /&gt;&lt;br /&gt;If you would rather not install our cool new Database Accelerator Suite, you will have to write some custom code to query SQL for the value. Around this code, you'll want to lock the DB. It's probably 20-30 lines of code, but more significantly, it will require full trust and hardcoding of the connection string in the solution. I recommend against doing those things because they make the form a) harder to deploy and b) more costly to maintain. Nevertheless, we have done it before and you *can* do it. If you need a code snippet, we'd be happy to spend a couple hours helping you write it. You can purchase a block of time in the store. &lt;br /&gt;&lt;br /&gt;Cheers!</description></item><item><title>Re: Checking input against DB for duplicates</title><link>https://www.infopathdev.com:443/forums/thread/3564.aspx</link><pubDate>Wed, 29 Nov 2006 13:03:43 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:3564</guid><dc:creator>mcalicea</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/3564.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=39&amp;PostID=3564</wfw:commentRss><description>Thanks for the idea, but in my case, the number is generated prior to being input into the form.  That is why I want to have it checked against the database, in case someone "fat-fingers" the entry and accidentally enters a duplicate number in.  Right now, SQL kills it after the submit button is pressed, but I would like to have the error found and notify the user before it gets to that point.  I have little to no experience programming with JScript or VBScript at this time.  Its on my list of things to do.</description></item><item><title>Re: Checking input against DB for duplicates</title><link>https://www.infopathdev.com:443/forums/thread/3563.aspx</link><pubDate>Wed, 29 Nov 2006 08:18:26 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:3563</guid><dc:creator>Patrick Halstead</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/3563.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=39&amp;PostID=3563</wfw:commentRss><description>Hi Mcalicea and welcome to our forum!&lt;br /&gt;Most of the time, people ask how they can set it up to have the DB automatically create the ID when an entry is added. It's probably better to have the DB do this especially if you have multiple writers since there will be some lag between submit and validation. You could have a situation where just after the check succeeded someone else added a row with the same ID. At any rate, best practice is to have the number generated server-side, since that's where the locking happens. Please search for "database row auto ID" or something like that and let me know if you don't find something.</description></item><item><title>Checking input against DB for duplicates</title><link>https://www.infopathdev.com:443/forums/thread/1689.aspx</link><pubDate>Tue, 28 Nov 2006 15:36:37 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:1689</guid><dc:creator>mcalicea</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/1689.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=39&amp;PostID=1689</wfw:commentRss><description>I'm sure its been asked before, but I can't find it here.&lt;br /&gt;What I have is a SQL 2000 DB with a single table.  I have a form made for the initial entry of data into the DB.  The first field on this form is also my Primary key and is unique to every row.  I am using the Data validation to ensure the format of this field is correct and that part works.  I need it to also check the DB to make sure there is not already an entry in the table with that unique number.  I tried creating a secondary data connection and comparing the two, but it doesn't work.  It never seems to find a match. I tried creating a rule but that didn't work either.  Please help.</description></item></channel></rss>