Search results

  1. S

    File Creation Date on Linked or Imported Text File

    I have multiple text files I link with an import specification. Is there a way to include the file creation date in the data if I link or import these text files. I currently import this data using sql in vba. The data from the linked text files is imported into another temporary table for...
  2. S

    Retain Sequence in Table from Original Imported Text File

    I use a macro to import a text file into a table. Each line of the text file contains 1 record. The type of record is identified by the 1st 3 characters (MR#). Multiple records contain related data but the only way to define the relationship is by the sequence of records in the original text...
  3. S

    file already in use message when trying to compact db

    I have multiple MDB files located on one computer which are used on that computer and others on our network. Until recently I was able to compact any of the MDBs as long as it was only open on one computer. There seems to be a problem with the file locking recently. If I close all open...
  4. S

    Help with Variable

    I can't think of any way to do this in a query. I think I need to do this in code so I can store a variable from the previous record. I want to create Field2. Field2 in the first record will always be 1. In each successive record if Field1 is "57" I want to use the same Fields2 value in the...
  5. S

    Concatentate a Single Field From Multiple Records

    I have a table of every reading of every electric meter. This history goes back a couple of years. Field1 = date Field2 = Meter# Field3 = Single digit code identifying method of reading The same meter is read multiple times in a year. The number of readings in the database is 1 or more (no...
  6. S

    Field Name Reference with Variable as Part of Name

    Can a function be written to create a field name reference using a variable(s) as part of the name? Example: A=1 B=2 Adding A+B should give the numeric at the end of the field name. I would like to refer to [Field3]. Something like [Field(A+B)].
  7. S

    Can't Design or Run Reports

    Has anyone heard of this before? I have a new XP computer with Office 2003. I can't seem to get reports in Access to work at all. I click on Reports then either design or wizard and nothing happens. I copied an mdb from another computer where everything works and can't run or open reports...
  8. S

    Default Values in Form from Table

    I have a form the runs reports based on a 2 values entered manually into text boxes. I would like to set default values for these boxes, but the values change twice daily. I've written a make table query that creates a table with the values I would like (only 1 record). I've inserted a macro...
  9. S

    Unmatch Query Question

    Table1 (New Data, Purged Periodically) Table2 (Archived Unique Records from Table1 not Purged) I'm trying to write an Unmatched Append query to populate Table2 from Table1 with records that don't already exist in Table2 Query (Doesn't work) SELECT Table1.Field1, Table1.Field2, Table1.Field3...
  10. S

    Unmatched Select Query

    I’m trying to write an unmatched select query and can’t seem to get it to work. I want to select data from Query1 that doesn’t already exist in Table1. There can be duplicate values in any field, but it should only be selected if the combination of values in all fields doesn’t exist in Table1...
  11. S

    Now() format different on different computers

    I've written a query that compares a date field in a database to the current date. It works fine on one computer but not on another. The problem is that one computer returns the date with a 4 digit year and the other 2. The date field in the database is YYYYMMDD I've written this to convert...
  12. S

    Trying to change Select into Delete Query

    I'm trying to change a select query to a delete query and can't seem to get it to work. I append records to my table [Keys] daily and one of the fields is the date the record was appended [Updated]. If there are records of a given [Cycle] with different [Updated] dates I want to delete all...
  13. S

    Comparing Different Length Text Fields

    How do you compare text fields that are different length? I have two fields, [Comment] (21 characters) and [ChgComment] (# of characters in field 0-21). The two fields usually contain the same characters, only the length is different. Under the Criteria for [Comment] I entered <>[ChgComment]...
  14. S

    IIf with Odd + Even Numbers

    I am trying to select records based on weather or not a field is odd or even. If the [Month] is odd the [CYCLE] s/b <=21 If the [Month] is even the [CYCLE] s/b >=22 IIf([Month] Mod 2=0,>"21",<"22") This doesn't return any records. IIf([Month] Mod 2=0,>21,<22) This gives me any error...
  15. S

    Date Range from Entry of Month + Year

    I'm trying to select records based on a date range which is automatically computed based on entry of only the month and year. The format is YYYYMMDD. I want to add a few days before the beginning of the month and a few after so I chose the 25th and the 5th as the days. If the month =1 and...
  16. S

    Search for " or - in a field

    I have a field that has either a quotation mark or a hyphen as part of the field. It would look like this. 9-153807 or 3" 503279 My question is how do I search for either a quotation mark or a hyphen in a field...
  17. S

    Query Problem W/Null Value

    This query works fine when there is a value in the [Route] field. It doesn't if it is null . I can fix this but it would require another embedded IIf statement that is a duplicate of the 2nd one. Is there an easier way? The first portion should apply only if the 1st character of the [Route]...
  18. S

    Page Break on 1st Character of Field

    I have a field in a report that represents a geographic area. The first character represents a large area and each succesive character narrows the area represented. How can I force a page-break based on a change in only the first character of the field. Here's an example 601-0530 602-0760...
  19. S

    Automatic Printer Selection?

    Is there a way to have a report automatically print to the correct printer based on a value in the report or a value in the query that generates the report. We print reports through our network in different district offices. We have a district field in our database which identifies the...
  20. S

    Return records based on user input

    WHERE iif([Enter value] is null, [FieldName] is null, [FieldName]=[Enter value]) The above works to return records with a value entered for a field, or all records with a null value in that field if there is no user input...
Back
Top Bottom