Query Not Working. - InfoPath Dev
in

InfoPath Dev

Use our Google Custom Search for best site search results.

Query Not Working.

Last post 09-13-2004 06:24 AM by BrownR. 5 replies.
Page 1 of 1 (6 items)
Sort Posts: Previous Next
  • 08-30-2004 11:53 AM

    • BrownR
    • Top 200 Contributor
    • Joined on 08-14-2004
    • USA
    • Posts 54

    Query Not Working.

    Im having another issue with my query not working. As a test for my form i made my text box a dropdown and it populates the dropdown with report numbers that are in the SQL database. BUT i cant get the rest of the information to populate. When i do a quesry with the dropdown or text box it returns a pop-up box telling me there is no file and that i can create a new file. Anybody have this happening? Also if i create another form with the same data-connection and same fields but just brought over to the form using the "section with controls", i can query the database and it returns my info! Anybody have any idea? Does it matter that i have a second dat-connection going to a xml file? or are there any field that i cant have in my "data" area that wont allow it to populate?
  • 08-31-2004 02:52 PM In reply to

    I'm not sure I follow you.

    First, if you can get it to work by just recreating the section, that might be the best thing to do. It could be useful to keep a copy of the one that doesn't work to compare it to the one that does work (i.e. use WinDiff or another tool to compare the before and after files). This is especially helpful for Microsoft to be able to fix issues if they exist.

    As for a 2nd data connection, it should not affect the first.

    Any field can exist in the data area or the query area. There is nothing special about those two areas -- they are just sections in the view. You can put your data or query fields anywher on the form. They are kept separate in the DOM. Visually, they can appear anywhere in the form.

    Greg Collins [InfoPath MVP]
  • 09-01-2004 06:29 AM In reply to

    • BrownR
    • Top 200 Contributor
    • Joined on 08-14-2004
    • USA
    • Posts 54
    Well I just got off the phone with MS. For what ever reason the form somewhere is calling SQL with a "Where" statment of "where 1 = 0". And thats when you call any of the records stored in SQL. Starting to sound like a Form issue.
  • 09-10-2004 06:56 AM In reply to

    • BrownR
    • Top 200 Contributor
    • Joined on 08-14-2004
    • USA
    • Posts 54
    Ok well this is fixed. Some how I or the form put a 1 in the default box on one of my query fields. BUT the field was never used or added to the form. Another words its on the data-pane but was never added to the form. So anything in default in your fields will have an effect on your form even if its not on the form. its crazy but thats how it works.
  • 09-10-2004 01:21 PM In reply to

    Glad you got it working.

    I make a quick check and it appears to not be a problem with the main data source fields. I created two fields in a blank form, made the default value for field1 to be "1". Then I removed it form the view.

    I didn't have any problem with the form or form template. This must be related to secondary data sources or queries.

    Greg Collins [InfoPath MVP]
  • 09-13-2004 06:24 AM In reply to

    • BrownR
    • Top 200 Contributor
    • Joined on 08-14-2004
    • USA
    • Posts 54
    The data field is in the main connection. I noticed the default was 1 on both the data and query. Im still daffled as why or how 1 was set to default.
Page 1 of 1 (6 items)
Copyright © 2003-2019 Qdabra Software. All rights reserved.
View our Terms of Use.