Search results

  1. simongallop

    Revolt of the append queries

    Not sure what you mean by cutting corners. Link the files so that you have 4 tables use the first table as a maketable query Apend the remaining 3 to the first one. So long as the field names are the same then there will be no problems otherwise you will have to go through the design grid...
  2. simongallop

    percentages, I know I did this wrong

    To get a list of how many time a salesperson hits a certain level you will need 2 queries. The first strips the description off the level so that it just has the numbers and sums it be occurence. The second creates the running total. The output looks something like: In Table: SP1, Lvl2 SP1...
  3. simongallop

    percentages, I know I did this wrong

    How about summing the levels that the salesperson has got to and viewing that as a percentage of total sales? (Can also count the number of records per salesperson and get an average level per trade) eg: SP1: Lvl5 SP1: Lvl3 SP1: Lvl3 SP1: Lvl7 SP2: Lvl9 SP2: Lvl1 Average over company: SP1...
  4. simongallop

    percentages, I know I did this wrong

    First of all are you replacing a customer record if they come in a second time eg: John Doe comes in 14 April and gets info on a bike. John Doe comes back 16 April and buys a bike. Is that 2 records or one record updated with the latest info? If 2 records how are you going to treat the data...
  5. simongallop

    Time Stamping Appended Record

    Presuming that you have a field called DateStamp or something. If you are basing it off the system date (ie if run today it would show todays date!) then: DateStamp: Format(DateAdd("m",-1,Date()), "mmm-yy") {Or whatever format you want it in} If you are taking the date from an existing field...
  6. simongallop

    The function does't run in the last part

    If any one is using this code please note that the 5th line in the function needs to be changed from: WholeDay = Int(EndDate - StartDate) to WholeDay = Int(EndDate) - Int(StartDate) HTH Harry
  7. simongallop

    How to write query that can recursively check values in a column

    Have done it by using code. First I did this with numbering starting at 1 so do not know if starting at 0 will be a problem. Test it and see! 2/: Create a table called tmpResult. It has 4 fields: UnitCode (Text) UnitName (Text) StaffTotal (Number) Vacancies (Number) Place primary key on...
  8. simongallop

    Another need zero values question

    Try this: You will need 2 queries. The first selects the records, the second gives the result In the following code I am calling the first query Selected_Records SQL for query Selected_Records: SELECT AgeReview.TeamIDRS FROM AgeReview WHERE AgeReview.ReviewDate Between [Please type...
  9. simongallop

    Another need zero values question

    Looking at the the 2 queries the bit that you changed in the second one is correct ie you are selecting TeamIDRS from Team_Info, whereas in the first one you used AgeReview. Therefore would have thought that this would work. SELECT Team_Info.TeamIDRS, Count(AgeReview.TeamIDRS) AS...
  10. simongallop

    parameter value?!?!?!

    How about creating a report based on the query value and printing that?
  11. simongallop

    Conversion 97-->00 (ODBC problem)

    Sorry to ask the obvious, but have you compared the reference libraries that you had in 97 and are now using in 2k? {Open a module and then on the toolbar, TOOLS, REFERENCES}
  12. simongallop

    The function does't run in the last part

    Not very good at debugging but try this (it seems to work!) Dim DayStart As Date Dim LunchStart As Date Dim LunchEnd As Date Dim DayEnd As Date Dim WholeDay As Integer Dim StartTime As Date Dim EndTime As Date Dim WorkedTime As Date Dim DaySecs As Double Dim TimeSecs As Integer Function...
  13. simongallop

    function for a report; KB article 129096

    If all you want is a grand total in the footer of your report then why not place a textbox there with the source being =sum([FirstOfGRegTo])?
  14. simongallop

    View records by associated user id

    Here is the code!: Function fOSUserName() As String 'Returns the network login name Dim lngLen As Long, lngX As Long Dim strUserName As String strUserName = String$(254, 0) lngLen = 255 lngX = apiGetUserName(strUserName, lngLen) If lngX <> 0 Then fOSUserName = Left$(strUserName, lngLen - 1)...
  15. simongallop

    View records by associated user id

    I agree that there must be a way but I do not know of it. Have you thought of adding the persons user ID to the client record and then limiting the query to view clients by ID. This way they would not need to enter there own ID as it would pick it up from the network (There is code somewhere...
  16. simongallop

    Best way to do this-complex if, then function?

    Create you table with 3 columns. Item_No, Price A, Price B Now you can return the value needed so if wanting B3 you would look at: DLookUp("[Price B]", "MyPriceTable","[Item_No]=3") Next step therefore would be: If you have a form with 2 textboxes and you want to return the price to a third...
  17. simongallop

    Please Help! Very Stuck!

    Oops posted at the same time!:)
  18. simongallop

    Please Help! Very Stuck!

    Open the form Coredata1 in design view. On the toolbar click View / Properties On the recordsource section at the far right is a small button with 3 dots (...). Click it A query builder view will show In the 5th column (Course Start) you will see some code in the criteria section...
  19. simongallop

    Problems regarding OpenRecordset

    If you are using acc2k or greater then make sure that you have DAO3.6 library loaded. (In the module window, toolbar Tools / References)
  20. simongallop

    Random selction error when importing

    Have you checked that you have the same reference libraries loaded (for Acc97 go to a module and then Tools / References on the menu bar, Acc2k go to the VBA editor and Tools/References)
Back
Top Bottom