Having trouble displaying data using tables from Sql database - InfoPath Dev
in

InfoPath Dev

Having trouble displaying data using tables from Sql database

Last post 08-28-2009 04:49 PM by MrsEstrada. 2 replies.
Page 1 of 1 (3 items)
Sort Posts: Previous Next
  • 08-26-2009 11:54 AM

    Having trouble displaying data using tables from Sql database

    Hi I'm trying to accomplish the following:

    User enters in an Asset Tag # (this goes into a free text box)
    The Asset Tag # is a unique identifier. Based on the # the remaining fields should auto popluate all required info that pertains to that # (make, model, serial #, vendor, warranty, etc..)

    I currently have 2 different sql data connections. The relationship tables are as follows:

    vAddInventory joined with vTransactionHistory (both have many common fields including the Asset Tag)

    vAssetInfo joined to both vAsset (by Asset Tag) and vSupplier (by Supplier #)

    I am using list boxes as this seems to be the only way I can properly display most of the data that I'm showing. I'm making the default value equal to the AssetTag but displaying whatever data I need to from the record/data string associated w/the Asset Tag # I'm entering. The problem is that some of the data is in the "child" tables and I can't get those fields to display any data. I'm stuck on how to match up the fields and I can't do any hard coding to the form.

    Sorry I hope I didn't ramble too much =)

  • 08-28-2009 04:21 PM In reply to

    Re: Having trouble displaying data using tables from Sql database

    Hi:

    So your form is not based off a database? You are simply wanting to display the information for a particular asset tag (no submit)? Do you need to also store the resulting information in an XML file?

    If all you need is to display the information from your secondary data sources, you can add repeating sections to your form bound to those data sources. Then, you can conditionally format those sections to only display if the Asset Tag is equal to the one selected.

    Hilary Stoupa

  • 08-28-2009 04:49 PM In reply to

    Re: Having trouble displaying data using tables from Sql database

    Hello,

    Yes to the first and last questions above and no to the second. The form will be designed to receive data form those data connections but not submit to them. I found out that w/out a web based connection to the sql server the form will not behave as I'd like.  I could display mostly all of the data that I wanted due to the majority of the tables have the ASSET TAG associated with them, but there is one table that does not. When I tried to add this table to another table which shared a common column I discovered that the files were not "joining". I figured it was due to the type of data connection. When I did attempt to edit the sql I kept getting a syntax error. I'm not familiar enough w/coding to try to correct it. The current data connection is just local and I was going to correct it once the form was working properly in "preview". Now I'm thinking I HAVE to have a sql web service connection,  unless you see another way around this?

     

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