Search results

  1. X

    Return a result when no records are found?

    Sure thing, and yes the original post was one of the subqueries, it counts the number of entries for each possible answer, lists them in descending order and then trims off the top 1 (hence giving the most common answer) SELECT TOP 1 Trends.Trend AS TBoxMode FROM Trends INNER JOIN [Toolbox...
  2. X

    Return a result when no records are found?

    Thanks for the tip CJ but it's still not helping :(, the numeric fields have no issue but the Mode queries still need to return something, else they bomb the whole thing. I see your point with Nz, Correct me if I'm wrong but the NZ function only seems to replace individual field results, so...
  3. X

    Return a result when no records are found?

    Hi all, Hopefully this isn't too difficult a question but experience tells me everyone that comes here is a genius... :) My question is, does anyone know of a way to build something into a sub-query that says 'if no records are found, return '0' or some other string'? Otherwise is there a way...
  4. X

    Search Query query :)

    Finally solved this issue so for the sake of anyone else reading I will explain: 1) Of course using the correct joins is the way to get all employees regardless of whether they have an entry in other tables - my issue was that some of the other tables were already related (thanks to the...
  5. X

    Multi-table search query to ignore null fields

    Finally solved this issue so for the sake of anyone else reading I will explain: 1) Of course using the correct joins is the way to get all employees regardless of whether they have an entry in other tables - my issue was that some of the other tables were already related (thanks to the...
  6. X

    Join smaller report on the back of main report?

    Just as I thought, I was being dim. If i make two reports for the high/Low severity cases, I can just put them both in as separate sub-reports so one prints after the other. Can anyone think why that wont work? otherwise I think it's cracked and I just wasted two hours learning pointless vba...
  7. X

    Join smaller report on the back of main report?

    Well I've been a little distracted by other jobs but I've had a little play and thanks for the tip :) I've used the tag property to group them all, and have told them all to disappear when the severity is low (see code). But a new problem has arisen, for some reason it happens on every record...
  8. X

    Join smaller report on the back of main report?

    Hi all, Apologies if I'm being dim but I need some ideas on the best way to solve my problem: I have a report that displays incidents, their details, consequences and a photo. Among the details is a severity rating high medium or low, I have been asked to make the report shorten the records...
  9. X

    Multi-Field Union Query

    Potentially - if I concatenate the ID's with another field it could be used as a makeshift ID. This could take some thinking, I'll have to play around a bit... Cheers for the advice,
  10. X

    Multi-Field Union Query

    hmm so in this example he union'd all the non-attachment fields via two new queries, giving all the question fields as needed, then joined that to the original questions table where the ID was the same... I see why this wasn't going to help me now, both of his queries came from the same...
  11. X

    Multi-Field Union Query

    Hi all, I have two tables containing (let's say for simplicity) questions and attachments (pictures). I am trying to perform a union query to join all the questions and pictures into one report, but it won't let me union the attachment because 'the multi-valued field 'TableA.Pictures' cannot be...
  12. X

    Two Count Queries into One?

    I am a dumb dumb. I can just select other queries to join into one. Like so: SELECT QueryA.QueryACount, QueryB.QueryBCount FROM QueryB INNER JOIN QueryA This certainly seems to do the trick... I'll be back if it doesn't! Thanks for reading! ;)
  13. X

    Two Count Queries into One?

    Sorry I'm not being clear. In this example I have two tables and I'm asking them (in two separate queries) how many records there are based on a criteria, like this: No:RecordsinA ------12------- and, No:RecordsinB ------09------- But what I want is a single query that I can make a report...
  14. X

    Two Count Queries into One?

    Hi all, (Please forgive my noobiness I am learning every day.) I want to be able to make a query that joins several other queries into one, but in parallel not in one column... I have used Totals and Count to show the number of records in a table where a certain criteria is true. I have done...
  15. X

    No 31st of January!?

    Thanks (as usual!) that is a much easier way to do it. :)
  16. X

    No 31st of January!?

    thinking on it, could the problem be the 'Or' in my function? that looks to be where I'm getting stuck... is there a better way to say if x = Y Or Z other than just writing each IIf individually? Good brainstorming :D
  17. X

    No 31st of January!?

    I had to double check too... for some reason my form wont pick up the 31st of any month in my input form (jan, mar, may, july, aug, oct, dec). I have a simple search form (no control source) that runs a query which is based on the records between two input dates (text boxes). These could be any...
  18. X

    Online forms enter new information?

    Hi all, I was wondering if it was possible/if anyone can tell me how, to convert one of my forms into html format such that (once hosted on my secure server), the user can enter information and will update the relevant table at the source database? I have seen a few tutorials for this but they...
  19. X

    Macro: if 'query returns no records'...

    You are fast becoming my favorite Tecchy :) this works perfectly thank you very much. I have deleted the other thread.
  20. X

    Macro: if 'query returns no records'...

    Hi all, I have created a macro which emails the results of a query to myself when I open the access database. - However, I only want it to do this if the query finds any records, otherwise it sends me a blank document half the time. - I have tried using the 'If' Program Flow so it either...
Back
Top Bottom