<?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>SQL Database Integration</title><link>https://www.infopathdev.com:443/forums/47.aspx</link><description>For questions concerning issues in the integration of SQL and Microsoft InfoPath.</description><dc:language>en</dc:language><generator>CommunityServer 2007 SP3 (Build: 31118.962)</generator><item><title>Re: Verify data between two SQL table data connections - Browser based form</title><link>https://www.infopathdev.com:443/forums/thread/81149.aspx</link><pubDate>Tue, 31 Jul 2012 03:07:36 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:81149</guid><dc:creator>Edwin Brito</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/81149.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=47&amp;PostID=81149</wfw:commentRss><description>&lt;p&gt;Without an screenshot is a little difficult to visualize your scenario. As far as I understand, it seems that this can be solve using a rule that assigns a value to the filed you want to calculate. A filter might be requiered to filter the value based on the parameters you defined.&lt;/p&gt;&lt;p&gt;Create a filed called&amp;nbsp;&amp;#39;location&amp;#39;&amp;nbsp;&lt;/p&gt;&lt;p&gt;Select the variable field (&amp;#39;employeeID&amp;#39;) and create a rule called &amp;quot;Location&amp;quot; &lt;/p&gt;&lt;p&gt;&amp;nbsp;&amp;nbsp; &lt;strong&gt;Conditions:&lt;/strong&gt; None&lt;/p&gt;&lt;p&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;strong&gt;Rule Type&lt;/strong&gt;: Action&lt;/p&gt;&lt;p&gt;&amp;nbsp;&amp;nbsp; &lt;strong&gt;Run these actions&lt;/strong&gt;:&amp;nbsp;&lt;/p&gt;&lt;p&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Set field value&lt;/p&gt;&lt;p&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Field: Location&lt;/p&gt;&lt;p&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Value: click on &amp;quot;fx&amp;quot;&amp;nbsp; &amp;gt; In the Insert formula dialog box:&lt;/p&gt;&lt;p&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;quot;Insert filed or Group...&amp;quot;&amp;nbsp; &amp;gt; Navigate to the location you want to insert&amp;nbsp;from the data connection (secondary)&lt;/p&gt;&lt;p&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Click on: &amp;quot;Filter the data...&amp;quot; &amp;gt; &amp;quot;Add...&amp;quot; &amp;gt; Create a condition where&amp;nbsp;the Zip Code&amp;nbsp;on the main connection is equal to the Zip Code on the secondary connection.&lt;/p&gt;&lt;p&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/p&gt;&lt;p&gt;,&lt;/p&gt;</description></item><item><title>Verify data between two SQL table data connections - Browser based form</title><link>https://www.infopathdev.com:443/forums/thread/81144.aspx</link><pubDate>Mon, 30 Jul 2012 21:20:45 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:81144</guid><dc:creator>Big E</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/81144.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=47&amp;PostID=81144</wfw:commentRss><description>&lt;p&gt;Alright, here is the skinny.&amp;nbsp; I have two sql tables that I am pulling in for a read only data connection.&amp;nbsp; I have setup a udc connection for both of these and they are working fine.&amp;nbsp; What I am trying to do is write a value to a field from one dataconnection based on a condition from the second data connection.&lt;/p&gt;&lt;p&gt;I currently get the value of &amp;#39;Zip Code&amp;#39; by creating a conditional filter on the datasources.&amp;nbsp; Here is the xpath for that statement:&lt;br /&gt;xdXDocument:GetDOM(&amp;quot;DATABASE_TABLE1&amp;quot;)/dfs:myFields/dfs:dataFields/d:DATABASE_TABLE_1/@ZIP_CODE[../@EMPLID = current()]&lt;br /&gt;Simple enough.&amp;nbsp; I receive the value of the first name based on the current employee ID that was selected in the dropdown that is performed by a rule.&lt;/p&gt;&lt;p&gt;Based on this, I would like to get a location name from a different datasource (DATABASE_TABLE_2) and have the data match up based on the zip code in DATABASE_TABLE_1.&amp;nbsp; Since the zip code would be the primary key in both data sources, I figure this would be the way to go.&lt;/p&gt;&lt;p&gt;I am having issues trying to get this worked out.&amp;nbsp; Does anyone know if this seems like it could work?&lt;/p&gt;&lt;p&gt;Thanks,&lt;br /&gt;Eric&lt;/p&gt;</description></item></channel></rss>