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 strongm 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: RosieGp
  • Content: Threads
  • Order by date
  1. RosieGp

    Excel - count only distinct IDs per month

    Hello - I'm trying to count distinct ids per month. but it is not working for me. worksheet1 A B C 1 ID tempDate DateValidation 2 12 11/12/2017 11/01/2017 3 14 12/23/2017 12/01/2017 4 16 11/17/2017...
  2. RosieGp

    select the row with max number of days btw the start and close date

    i have table with column that have duplicates with different start and end date. Table1: Product startDate endDate Desc A0987 05/01/2017 05/05/2017 Traiging A0987 05/01/2017 05/05/2017 Traiging A1234 05/02/2017 05/03/2017 Driver Mag A1234...
  3. RosieGp

    To get data in one table that is unmatched in multiple other tables

    Table1 ColoraddedJan Red Yellow Green Table2 ColoraddedFeb Purple Orange Table3 ColoraddedMar White Black ComparingTable Coloradded dateadded dateused Red 1/1/2017 3/1/2017 White 2/4/2017 4/4/2017 Purple 1/1/2017 5/1/2017 Pink 2/3/2017 4/3/2017...
  4. RosieGp

    JOIN query help needed

    Hello - i have following 3 tables: tbl_Rating ID ProductNumber Rating 1 C_10, C_11 5 1 C_10, C_11 4.5 3 F_12 2 4 CH_3 3 tbl_Sold ID ProductName Dealer ProductSOld 1 Chevy Cruise Sam 2 3 Fiat Compact Darcy 1 4 Chysler Van Donny 1 tbl_Product ID Brand 1 Chevy 2 GM 3 Fiat 4 Chysler SO far i...
  5. RosieGp

    SQL JOIN on 2 tables with a list and column ID

    How can I Join on KidsData and Fruitdescription table to get Fruit Name from Fruitdescription table rather than hard coding it. this is what I can get to this far. <cfquery name="kidsData"> SELECT * FROM KidsData K LEFT JOIN Fruitdescription F ON F.ID = K.FruitData WHERE FruitData IS...
  6. RosieGp

    How to read string of 0s and 1s

    I have a table of kids(5) and which of the 6 fruits they bring: Table: KidsData ID Name FruitData 1 Candy 100000 2 Andy 001000 3 Sarah 001010 4 Gabby NULL 5 Jack 000110 Table: Fruitdescription ID FruitName 1 apple 2 orange 3 kiwi 4 banana 5...
  7. RosieGp

    SQL insert into and select query

    I need a query which writes to a table (if data is missing) and then based on the logic return a value (TRUE/FALSE) if the procedure needs to be executed. I have following (not functional) query: Declare @MissingData varchar(6) = 'TRUE' Insert INTO MissingInfoTable (CustomerID, NoOfEntries...
  8. RosieGp

    JOIN query

    Hi, I had the following query to join on 2 tables kwhich worked perfectly fine. SELECT Customer.Customer.FName, Supplier.* FROM Customer INNER JOIN Supplier ON Customer.ID = Supplier.ID WHERE Supplier.process=True AND Supplier.processDate Is Not Null Now I want to Join another table Product...
  9. RosieGp

    Update query

    I have the follwoing query that is updating the data in table SupplierTable1 UPDATE SupplierTable1 SET TodayDate = '#DATEFORMAT(Now(), "mm/dd/yyyy")#', Suppliermail = '#form.Supplieremail#', SupplierStreet = '#form.SupplierStreet#', SupplierCity =...
  10. RosieGp

    how do i write it in access. my tab

    how do i write it in access. my table is in access... and i'm using coldfusion (CFM) to call this query. I tried the following but it does not work: the record is added to Database even if the ID exists. <cfquery name="GetData" datasource="MainDB"> SELECT * FROM NewUsersTable <cfif...
  11. RosieGp

    Insert and update/append in coldfusion

    how do i write it in access. my table is in access... and i'm using coldfusion (CFM) to call this query. I tried the following but it does not work: the record is added to Database even if the ID exists. <cfquery name="GetData" datasource="MainDB"> SELECT * FROM NewUsersTable <cfif...
  12. RosieGp

    Insert and update/append to existing data.

    Hi, I have the following Insert query: (all this data is coming from a form) <cfquery name="insertdata" datasource="MainDB"> INSERT INTO newUsersTable (NewUserTodayDate, UserID, UserFirstName, UserLastName, UserAddress , UserPhoneNumber, UserComments) VALUES ('#DATEFORMAT(Now()...
  13. RosieGp

    SQL BETWEEN

    I have this query to return records between this date to that date as following: Select * from Employee where Employee_ID = 1 and convert(varchar(10), DateofVAcation,101) between '12/01/2010' and '01/01/2011' This won't return anything. If the data in Between clause is of the same year...
  14. RosieGp

    SQL Group By

    I have the following query: Create Procedure Emp_Data @ID varchar(10) AS select distinct Emp.ID, Emp.Employee_Name,Emp.Job_Status, EA.Employee_Address, EA.UpdatedAddress, EA.Update_Time, EW.TaxForms, EW.TFDate from Employee Emp left JOIN EmployeeAddress EA ON EA.ID = Emp.ID left...
  15. RosieGp

    Update select and compare 2 tables...

    I have the following tables: Employee ID Name Job_Status 6789-1 Joe N 6789-2 Joe N 6789-3 Joe N EmployeeQualification ID Name Qualifications Acquired_Date 6789-1 Joe...
  16. RosieGp

    SQL select where

    I need to make some adjustment to a store Procedure, more like the select statement: @EmployeeNumber varchar(15) select ID, EmployeeNumber, EmployeeName, from EmployeeTable where ID = @EmployeeNumber Ok i have 4 tables EmployeeTable, EmployeeAddress, EmployeeRequest, EmployeeLog Now...
  17. RosieGp

    SQL select where

    I have the following query: Select [ID],[EmployeeNum],[EmployeeName],[DateStarted], [DateCompleted] From [EmployeeLog] EL where exists (select 1 from [EmployeeAddress] EA where EA.JobStatus = 'Y' and EA.ID = EL.ID and EA.EmployeeNum...
  18. RosieGp

    SQL select query

    Ok in my Employee_YearsOfWork table... I have the following: Employees_YearsOfWork ID Years Date_Completed 1-1 2 Dec - 12 12-2 7 June - 15 12-5 15 Aug - 11 I have to just display Date_Completed as following: Employees_YearsOfWork ID Years...
  19. RosieGp

    Sql Select Union

    Hi, i have 2 tables as following: Employee_Info ID Employee_Name Date_Started SickDays 1-1 Joe Mar 1 2 12-2 Randall Feb 2 5 12-5 Pam April 9 6 Employees_YearsOfWork ID Years Date_Completed 1-1...
  20. RosieGp

    SQL select based on 2 tables

    Hi, I have another issue today... In my DB I have 2 tables. Employee_Info, Employee_Address. I'm trying to retrieve information from the Employee_Info based on a condition in Employee_Address. Employee_Info ID Name EyeColor Job_Status 1 Joe black Y 2 Dan...

Part and Inventory Search

Back
Top