Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Search results for query: *

  • Users: emmy
  • Order by date
  1. emmy

    Stored Procedure executing several commands

    I've create a series of short commands that make some modifications to some tables. I figured since they must happen sequentially that I would create a stored procedure that runs all of them. It works fine, but I worry that as the database grows and each command takes more time, that the...
  2. emmy

    Subform listboxs based on main form

    Well, I did that in the beginning but I found that I also need to re-apply the location number in the rowswource SQL of the listbox. I'm wondering how I can get the listbox to use only the people from the location that is selected in the main form. ie - have the listbox use the results from the...
  3. emmy

    Subform listboxs based on main form

    I have a main form from which a user can select a location from a combo-box. I've added a tab with a sub form showing address, phone etc. I've added another tab and sub form, I want this second sub form to have 4 list boxes which list people in each job at the location selected in the main form...
  4. emmy

    MS query on SQL database date paramaters

    Skip, that's closer than I've gotten on my own. The error I get with the datevalue function is "Datevlue is not a recognized built-in function name. Statement could not be prepared." I suppose it's because this is a SQL database so I'm trying to compare a date-time field to a date only. Added to...
  5. emmy

    MS query on SQL database date paramaters

    I have a SQL database, I've written a report in crystal reports that works great. I want to pull the same data into excel. If I use the same sql in MS Query I get errors on the date. Here is the code as it is used in Crystal, can someone help me make it MS Query compatible? SELECT...
  6. emmy

    Nested query 3rd level

    What I found out is I have 3 criteria, so had to have a 3-deep nested query. EMPLID (employee id)- the '0' EMPL_RCD (employee record), the latest date, and if one date has more than one transaction, the latest transaction (EFFSEQ) Here is the code that works - SELECT a.EMPLID, a.EMPL_RCD...
  7. emmy

    Nested query 3rd level

    Sometimes a person is terminated at one location, then hired at another. This transition will be recorded on the same day. So on Effective Date Aug 8 Jane could be terminated at location A (EFFSEQ0), then hired at location B (EFFSEQ1). For whatever reason, if I change the first chunk to read...
  8. emmy

    Nested query 3rd level

    I've gotten my query this far, however if 2 actions happened on a record on the same day - I get 2 results for that record. Say a person 006 changed locations and got a raise on the same day, they will have EFFSEQ 0 and EFFSEQ 1 for that day - thus giving me 2 records for person 006 in my...
  9. emmy

    inner join, group by sytax errors

    Well, I discovered that some people were missing. So back to the drawing board! These two queries work when run independent of each other, but I've messed up the join again. It says it can't find the column 'MAX_EFF_DATE'. If I take that out, it still runs but only if I increase the timeout by 3...
  10. emmy

    inner join, group by sytax errors

    Thank you to both of you. The query is now working great, and I've learned a little more about the mysterious world of SQL.
  11. emmy

    inner join, group by sytax errors

    I'm sure the problem with this SQL goes deeper than syntax error. This worked great before I tried to add email addresses to my results. Syntax error on line 13 and 23: (SELECT a.EMPLID, a.EMPL_RCD, a.EMPL_STATUS, a.HR_STATUS, a.EFFSEQ, a.ACTION, (CONVERT(CHAR(10),a.[EFFDT],110)) AS...
  12. emmy

    Count Unique Record in Report Footer

    I've decided that in order to get the allocation for the state to show in the header, then I'll just have to re-create the form as main form and sub form. The original designer put a ton of formatting in the form, and I was too lazy to recreate it! Admittedly, doing so in the first place would...
  13. emmy

    Count Unique Record in Report Footer

    This is close to what I need help with. I have State, County, Category, Allocation. The query that is already the control source of the report I am modifying (to group by state) will return results like: State County Item Allocation Washington, County1, Printers, $1,000.00...
  14. emmy

    Combo box value will not display

    Oh, duh. Me.cmbLocName.Value = Me!LocNum Column Width = 0",2" cmbLocName is now equal to the locations number (to reference later) and the box shows the location by name. Sorry.
  15. emmy

    Combo box value will not display

    Being curious, I changed the column width property from 0",2" to 2",2" - now I can see my value. I'm still confused because my row source is: SELECT locations.LocNum, locations.LocName FROM locations ORDER BY [LocName]; Shouldn't the box now show LocNum, LocName (ex 1225,Alpine)? Have I gone...
  16. emmy

    Combo box value will not display

    Yeah, I tried that. Still doesn't display. Thanks for the suggestion though.
  17. emmy

    Combo box value will not display

    My form has a combo box 'Programs' in the header. When a program is selected the form displays all the data for that program. Works great with text boxes. One text box displays the location of the program. Programs can move to other locations, so I would like to have the locations box be a combo...
  18. emmy

    Combine tables with duplicates

    You know what? When In pasted in the code and started writing an explanation... I realized my error. I was pulling the phone number & grant info from the ONE table rather than the MANY table. Good grief. Just goes to show, sometimes it's good to walk away for awhile! Thanks for asking!!!!
  19. emmy

    Combine tables with duplicates

    I have 2 tables, PhoneAccounts and PhoneInventory. PhnoneInventory has Primary Key "PhoneNumber" (no Dupes). PhoneAccounts has PrimaryKey "PnoneNumber" (Dupes OK). PhoneAccounts does have some duplicate phone numbers because one phone may be paid for by 2 grants. I need a...

Part and Inventory Search

Back
Top