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: BrockLanders
  • Order by date
  1. BrockLanders

    If table exists...

    Thanks guys or gals (can't tell by your screen names) the code works.
  2. BrockLanders

    If table exists...

    Hi, I want to check the current database if a certain table name exists. If so, delete that table, otherwise, run some other code. The problem I'm having is referencing the table name. Below is my code currently: Chain = InputBox("Enter chain number. Do not zero fill") If...
  3. BrockLanders

    Simple filter on form

    I'm trying to filter a form whose source is a table. I'm filtering on a date field, but it's not working. I'm not using code to do the filtering, just the Form properities window. I'm trying to only return those records where the date is 12/7/05. In the option for Filter, I'm typing...
  4. BrockLanders

    Grouping in form?

    I just changed the two fields that are being summed - SalesQty and SalesWhsl to other number fields. SELECT H.Store, Sum(H.BegInvQty) AS SumOfBegInvQty, Sum(H.BegInvWhsl) AS SumOfBegInvWhsl, D.Format_date & '' As Period, H.EndDate & '0' AS SortId FROM [HEB July 05] AS H INNER JOIN tblDates AS D...
  5. BrockLanders

    Grouping in form?

    PHV, I tried the new code and got the same error. Is this query suppossed to give me the three sets of numbers, detail, weekly, monthly? Thanks again
  6. BrockLanders

    Grouping in form?

    When I try to run the query i get the following error: "Syntax error (missing operator) in query expression 'Max(H.EndDate) & '1' GROUP BY H.Store'." I've looked at the code a million times and can't find any syntax errors. Any ideas? Thanks for all your help with this PHV!
  7. BrockLanders

    Grouping in form?

    Oops, sorry about that. Store and EndDate are Text and Format_date is Date. EndDate is yyyymmdd so for grouping purposes I connected it to the table tblDates. Thanks
  8. BrockLanders

    Grouping in form?

    This code would give me all the potential data: SELECT [HEB July 05].Store, Sum([HEB July 05].SalesQty) AS SumOfSalesQty, Sum([HEB July 05].SalesWhsl) AS SumOfSalesWhsl, tblDates.Format_date FROM [HEB July 05] INNER JOIN tblDates ON [HEB July 05].EndDate = tblDates.Mainframe_date GROUP BY [HEB...
  9. BrockLanders

    Grouping in form?

    No, I don't need an updatable recordset. I don't quite understand how to construct the Union query though. SHould i first make three Select queries and then combine them in one union query and use that as my control source in the form? Thanks much.
  10. BrockLanders

    Grouping in form?

    Hi all, Is it possible to do a grouping in Forms like Reports? For example, I have daily sales data that I'd like to sum by the week, while showing all the daily detail as well and then have a grand total at the bottom. Getting the grand total is not a problem (Sum statements in footer), but I...
  11. BrockLanders

    import text file

    ok, i'll look into renaming the fields after it's already imported. thanks for your time.
  12. BrockLanders

    import text file

    the problem is once a week, i'll be importing 52 rolling weeks of data, with each column/field named one of those weeks. for example, this week field 1 would be 6/18/05, field 2 would be 6/25/05, field 3 would be 7/2/05 and so on. however, next week field 1 will be 6/25/05, field 2 7/2/05...
  13. BrockLanders

    import text file

    i want to change the name of the fields each week when i import new data. one of the field names will be the current week. i'm not looking for ready made code how to perform this, just something to get me started - specifically what coding just to import data and name fields. i can figure out...
  14. BrockLanders

    import text file

    Hi, can anyone help me with some quick and dirty code to import a text file into an Access db, which allows me to name each field as it's imported? I've looked at the TransferText method of the DoCmd, but it doesn't look like you can name the fields, other than the first row of the file...
  15. BrockLanders

    Between function

    That worked perfect!! Thank PHV, have a star.
  16. BrockLanders

    Between function

    Below is my SQL, but I'm getting the same error, is there something wrong with my syntax? This is a find unmatched query. SELECT [2005 Inv Sched].[Store #], [2005 Inv Sched].Date, FROM [2005 Inv Sched] LEFT JOIN [Sched RGIS] ON [2005 Inv Sched].[Store #] = [Sched RGIS].[Store #] WHERE...
  17. BrockLanders

    Between function

    Hi, I have a query with a date field and want to add criteria to only return records between certain dates. In the criteria section of the query for the date field I have Between [Enter a beginning date] And [Enter a ending date], which brings up two input boxes asking the user for each date...
  18. BrockLanders

    reference text variable in VBA

    I think this might workDtTxtBx = Forms![Form1]![Text13].[Value] DtToday = Date() 'Get new Activity Data query = "SELECT * FROM qryDates Where [Start Date] Between '" & DtTxtBx & "' And '" & DtToday & "' order by [ChainName]"
  19. BrockLanders

    reference text variable in VBA

    The hash marks (#) is for when it's actually formatted as a Date/Time field. My Start Date field is a text format.
  20. BrockLanders

    reference text variable in VBA

    Hi, I have the below code, but keep getting an error (Invalid argument, Expected 1) on my execute line. DtTxtBx = Forms![Form1]![Text13].[Value] query = "SELECT * FROM qryDates Where [Start Date]>= '" & DtTxtBx & "' order by [ChainName]" My Start Date field is a text format (yyyymmdd) and...

Part and Inventory Search

Back
Top