Run Query, Return SQL Table Data - InfoPath Dev
in

InfoPath Dev

Run Query, Return SQL Table Data

Last post 02-01-2010 02:17 PM by jdog29. 2 replies.
Page 1 of 1 (3 items)
Sort Posts: Previous Next
  • 01-21-2010 04:20 PM

    • jdog29
    • Not Ranked
    • Joined on 01-21-2010
    • Posts 2

    Run Query, Return SQL Table Data

    I have Infopath 2007 form that allows user to input data and submit to a SQL server table.

    This part works great.  Now what I need is on the same form, some way to show the data in that table.

    How do I get the Run Query button to display the whole table data, like excel can do with a pivot table data connection.

    Or maybe only show the data the user entered for today.

    Any help would be greatly appreciated.

    Thanks All.

     

    JDog29

  • 01-21-2010 07:43 PM In reply to

    Re: Run Query, Return SQL Table Data

    You could add a secondary data connection to the table. Add an action to a button to query the new data source, put a repeating table control on the form and add some filters to it to limit the data displayed. Keep in mind that the bigger your table gets, the more records a query would pull -- so you may have an impact on your form's performance (that's one of the problems that DBXL solves -- it allows you to create filtered SQL queries without code).

    Hilary Stoupa

  • 02-01-2010 02:17 PM In reply to

    • jdog29
    • Not Ranked
    • Joined on 01-21-2010
    • Posts 2

    Re: Run Query, Return SQL Table Data

    OK, Thanks Hilary that helped a lot.

    I now have two sections on the form.

    The first section is where user enters data and submits.  This part works great.

    The second section is where I now have a repeating table that displays the table of all the data that users have entered in section one for past 10 days.  To do this I modified the SQL statement of the secondary connection.

    The problem I now have is when I click Run Query button, it only displays the first record in section one on the form.

    Section two is just a table showing data for past 10 days.  This works, but what if they need to edit one of these. What I would like to have, is a few data elements that the user could enter and query and it would populate the form's section one. 

    They could then edit and submit to overwrite record.

    Does this make sense and is it possible?

    Thank You.

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