Page 1 of 3 123 LastLast
Results 1 to 15 of 38
  1. #1
    5 Star Lounger
    Join Date
    Jan 2001
    Location
    Fontana, California, USA
    Posts
    625
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Unwanted Parameter request (XP)

    Edited by HansV to reduce HUGE screenshot in size.

    Me again - made a query that actually worked - now trying to make a report of the results of the query and I keep being asked for a parameter for each of my table headings. I don't want to answer any questions - I just want the results of the query in report form! Help, please. Have attached a snagit of what, I hope, all the elements look like.

    Thanks again

    AuntLinda

  2. #2
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Unwanted Parameter request (XP)

    I'm afraid that doesn't give us much information. Could you post a stripped down copy of your database? See <post#=401925>post 401925</post#> for instructions.

  3. #3
    5 Star Lounger
    Join Date
    Jan 2001
    Location
    Fontana, California, USA
    Posts
    625
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Unwanted Parameter request (XP)

    OK - turns out I also need the query to look at the square feet of the buildings that are "yes" in the table and if the square feet = 720 count that as half a building. Sorry!

    I'll try real hard to follow any instructions - I'm really struggling with Access . . . and I have to make a really, really complicated database sooner rather than later.

    Again - thank you.

  4. #4
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Unwanted Parameter request (XP)

    Open your report in design view.
    Activate the Data tab of the Properties window.
    You'll see a list of field names in the Order By property; these fields occur in the 'all data' table, but not in the 'temp bldg count by site' query that acts as record source for the report. Hence the parameter prompts.
    Clear the Order By property, then save the report.
    It should now open correctly.
    If you want to specify a sort order for the report, you can do so in the Sorting and Grouping window (select View | Sorting and Grouping to display it).

  5. #5
    5 Star Lounger
    Join Date
    Jan 2001
    Location
    Fontana, California, USA
    Posts
    625
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Unwanted Parameter request (XP)

    Perfect! What could I have done in the query that would have prevented the Order By property from the list of field names in the report?

    Thank you!

    Linda

  6. #6
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Unwanted Parameter request (XP)

    I assume it was copied from the Order By property of the table, but why, I don't know. Since the query has only two fields, the long Order By list doesn't apply to the query or report.

  7. #7
    5 Star Lounger
    Join Date
    Jan 2001
    Location
    Fontana, California, USA
    Posts
    625
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Unwanted Parameter request (XP)

    Good answer! I totally appreciate anyone who admits "I don't know" when they don't.

    Did you happen to have time to devote to the really hard part I asked in a subsequent post about writing a query that will look at the sq ft in the table and count temporary buildings with 720 sq ft as half of a building?

    Linda

  8. #8
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Unwanted Parameter request (XP)

    > I also need the query to look at the square feet of the buildings that are "yes" in the table and if the square feet = 720 count that as half a building

    On which column (field) do you want to select "Yes"?

  9. #9
    5 Star Lounger
    Join Date
    Jan 2001
    Location
    Fontana, California, USA
    Posts
    625
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Unwanted Parameter request (XP)

    Temp Bldg

  10. #10
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Unwanted Parameter request (XP)

    All records for which Temp Bldg? is "Yes" have 960 square feet, so you can simply use the straight count.
    By the way, you shouldn't put "Yes" in the criteria line of the CountOfTEMP_BLDG? column - this column returns a number.
    Instead, add the Temp Bldg? column another time, set the Total option to Where to indicate it is used to specify criteria only, and enter "Yes" in the criteria line for this column.

  11. #11
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Unwanted Parameter request (XP)

    I think the attached will do what you want; look at the design of the query to see how the area is taken into account.

  12. #12
    5 Star Lounger
    Join Date
    Jan 2001
    Location
    Fontana, California, USA
    Posts
    625
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Unwanted Parameter request (XP)

    The stripped-down version didn't have any schools that have buildings which are a total of 1,440 square feet and are divided into 2 rooms of 720 sq ft each - I need to know the number of rooms AND the number of buildings all the time.

    The database you sent me shows two fields - SITE and Number of temp buildings and in the "temp bldg" column, in the Total row, i see the word "Expression" but I have no clue WHAT expression was used!

    Hope this clarifies this a little bit - if it doesn't I'll try again . . .

    Happy Friday!

    AuntLinda

  13. #13
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Unwanted Parameter request (XP)

    If you widen the second column in the query design, you'll see the expression:

    Number of temp buildings: Sum(IIf([SPACE_SQ_FT]=720,0.5,1))

  14. #14
    5 Star Lounger
    Join Date
    Jan 2001
    Location
    Fontana, California, USA
    Posts
    625
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Unwanted Parameter request (XP)

    All of the records for which Temp Bldg? is "Yes" do NOT have 960 square feet - that's why the expression is more complicated than I can do myself yet - sometimes the number is 720 because THAT building is 1440 sq feet but I need to know that it contains 2 rooms - each 720 sq feet - but then count it as only 1 building.

    Plus - as long as I'm asking - why are there 2 of the letter "I" at the beginning of the expression?

    Thanks again for being so patient - if I get to stupid, just stop helping me - I'll understand!

    Linda

  15. #15
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Unwanted Parameter request (XP)

    IIf is a VBA function, it stands for Immediate If. Its syntax is

    IIf(condition, value_if_true, value_if_false)

    If the expression in the database I posted does not do what you want, you'll have to provide more details about what exactly you want the result to be.

Page 1 of 3 123 LastLast

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •