<?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: Querying two fields based on one request</title><link>https://www.infopathdev.com:443/forums/thread/57094.aspx</link><pubDate>Mon, 19 Jul 2010 20:21:50 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:57094</guid><dc:creator>oldradio99</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/57094.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=47&amp;PostID=57094</wfw:commentRss><description>&lt;p&gt;&lt;BLOCKQUOTE&gt;&lt;div&gt;&lt;img src="/Themes/infopathdev/images/icon-quote.gif"&gt; &lt;strong&gt;Skarn:&lt;/strong&gt;&lt;/div&gt;&lt;div&gt; 
&lt;p&gt;Go to Data Connections - main connection, and &amp;#39;edit SQL&amp;#39; - see if you can&amp;#39;t figure out how to put a WHERE clause on it that looks at the values of both a1 and b1 and see if this allows you to accomplish - if not - I have my own approach using jScript. Can you use jScript?&lt;/p&gt;
&lt;p&gt;&lt;/div&gt;&lt;/BLOCKQUOTE&gt;&lt;/p&gt;
&lt;p&gt;The trouble as I see it is that the typical &amp;quot;where&amp;quot; clause is not in the SQL query of the data connection but inherent in the IP form itself. Adding a where clause would just limit the data available to the form.&lt;/p&gt;
&lt;p&gt;The data connection to the table has query fields and data fields and neither can be manipulated.&lt;/p&gt;
&lt;p&gt;Maybe there is something in the source files that woudl let me manipulate but have not found a solution yet.&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;</description></item><item><title>Re: Querying two fields based on one request</title><link>https://www.infopathdev.com:443/forums/thread/57064.aspx</link><pubDate>Sat, 17 Jul 2010 14:46:46 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:57064</guid><dc:creator>Skarn</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/57064.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=47&amp;PostID=57064</wfw:commentRss><description>&lt;p&gt;Go to Data Connections - main connection, and &amp;#39;edit SQL&amp;#39; - see if you can&amp;#39;t figure out how to put a WHERE clause on it that looks at the values of both a1 and b1 and see if this allows you to accomplish - if not - I have my own approach using jScript. Can you use jScript?&lt;/p&gt;</description></item><item><title>Re: Querying two fields based on one request</title><link>https://www.infopathdev.com:443/forums/thread/56943.aspx</link><pubDate>Wed, 14 Jul 2010 22:29:32 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:56943</guid><dc:creator>Hilary Stoupa</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/56943.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=47&amp;PostID=56943</wfw:commentRss><description>&lt;p&gt;Hi:&lt;/p&gt;
&lt;p&gt;Does the form have to submit to the DB? I think if you build the form off a SQL view, you could do this, but if you build off a view you won&amp;#39;t be able to submit....&lt;/p&gt;
&lt;p&gt;Otherwise, I fear you may have to modify the query in code....&lt;/p&gt;</description></item><item><title>Querying two fields based on one request</title><link>https://www.infopathdev.com:443/forums/thread/56793.aspx</link><pubDate>Tue, 13 Jul 2010 12:47:18 GMT</pubDate><guid isPermaLink="false">033a2e2d-04e2-4a9d-be01-a4634161eefd:56793</guid><dc:creator>oldradio99</dc:creator><slash:comments>0</slash:comments><comments>https://www.infopathdev.com:443/forums/thread/56793.aspx</comments><wfw:commentRss>https://www.infopathdev.com:443/forums/commentrss.aspx?SectionID=47&amp;PostID=56793</wfw:commentRss><description>&lt;p&gt;I have been mulling this over for about a week and can&amp;#39;t seem to come up with a logical approach.&lt;/p&gt;
&lt;p&gt;I have ID#&amp;#39;s stored in two different fields in a SQL database; fields a1 and b1.&lt;/p&gt;
&lt;p&gt;Normally I would have a1 in the IP query box and that would search a1.&amp;nbsp; A nice&amp;nbsp;1 for 1 relationship.&lt;/p&gt;
&lt;p&gt;But now I (actually my end users) would like one field (call it c1) to look at a1 and b1 and return any records where xxxx exists in either a1 or b1.&lt;/p&gt;
&lt;p&gt;I can create a SQL view of the data if necessary and modify data there if cant be done in IP.&lt;/p&gt;
&lt;p&gt;Any ideas are welcome.&amp;nbsp; This Forum has alwasy been good to me.&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;</description></item></channel></rss>