I want to use an incremental number as a reference for records in a database. No probs, I use an autonumber. But the user wants the reference to start from 275.
Does anybody know how to start an autonumber off from a higher number (eg 275), without first creating and deleting 274 records. Is there an easy way of doing it.
Or should I not be using autonumber for this, but rather some other wizzy method which somebody is prepared to show me.
I have a table with a compound key, and one of the two fields in the compound key has to start at 100 and finish at 999 and I'd like it so that each number didn't have to be typed in individually.
So I thought about using an autonumber that somehow starts at 100 but doesn't go over 999 if thats possible? Or if you have any other ideas on how I could achieve this? Thanks
I have a table with a compound key, and one of the two fields in the compound key has to start at 100 and finish at 999 and I'd like it so that each number didn't have to be typed in individually.
So I thought about using an autonumber that somehow starts at 100 but doesn't go over 999 if thats possible? Or if you have any other ideas on how I could achieve this? Thanks
Is there a way to automatically choose a value such as 0 if the expression goes to a negative number?
E.g. I have a query that will subtract a numeric field from 10. If 10 - [numericfield] is less than 0, then I only want it to display 0. Otherwise, it can display the value if it is positive.
I need to write a query based on the higher MTD sales in the series of each fabrics within series of Sales Group and Prod Group . All info is from one table
Order by: Sales Group (alphabetical ord) , Prod Group (alphabetical ord) , sort Fabric Group based on the TOP MTD sales
Sales Gr: Active Prod gr: Adult, Girls, Plus, LG Fabric Gr: a,b,c,d,e,f... StyleNum: 1,2,3,4,5,6...(PK)
My database is written in Access 97 (I know get out of the stone age) but we have a mix of office 97 and office 2003 users. Anyway I'm afraid that one of the few people that have access 2000 or higher will open my database and convert it. I found (through here) code to check the version but it is attached to a form opening which is way to late. Is there a way to have access check the version as soon as you click to open the database and if it isn't 97 close the database?
I am developing a database and testing it with dummy data. With 50,000 records, the query process using SQL command is just OK. But if I double the total records, the query process takes longer time. The query is to make recapitulation using SUM of SQL command based on certain criteria. Any idea to make the query faster?
When I attempt to use the me.field = me.combobox.column() method to retrieve info from another query,it only works if I use column 0 or 1... it doesn't work with higher columns number.
- field name: cbofi - row source: listado-unico-fi <-- it is a query with unique values and 7 fields in total - event procedure, change:
Private Sub cbofi_Change() Me.txtDOCTPT = Me.cboFI.Column(1) Me.campovia = Me.cboFI.Column(5) End Sub
- txtDOCTPT is the field that indeed works - campovia is the one that does not work
I tried using column(0) and column(1) and it worked fine... but higher column numbers do not work. Just mentioning because the field names are all right.
I have two tables linked to each other in one to many relationship. Instead of auto number, the date and shift (Text) is being used as the primary keys (Composite Primary Key). Here is the tables structures,
The tables Payouts and Bills has one to many relationship. One payout row can have many bills. The problem is that I want to start the Autonumber in bills table everyday from 1. As date and shift are different for every day so even if i start bills from 1 everyday, it wont make same primary key. I can do it manually but I want to make it automatically.
I've been asked to get some information from my database and I'm a bit stuck.
I have a list of refunds in tbl_main and each one includes a dateReceived. I make a record in either tlk_located, tlk_unableToLocate or tlk_bulk depending on the outcome when we're trying to send the money back to whoever it belongs to. Each table has a time stamp (named locatedTime, unableTime and timestamp respectively) field
My manager wants me to report how many entries were unworked on each day in the year, and what the value of them was. An entry is unworked if there is no entry in either of the 3 tables.
So I need a query that lists a range of dates, and for each date counts the number of entries where tbl_main.dateReceived is <= to that date and either has no record in located,unable or bulk or has a record with a timestamp > than the date. (It has been processed now, but hadn't been on the date we are looking at)
I can manage a query that looks at a certain date that it prompts for on each run:
Code: SELECT Count(tbl_main.trust2PK) AS CountOftrust2PK, Sum(tbl_main.amountRefunded) AS SumOfamountRefunded FROM ((tbl_main LEFT JOIN tlk_located ON tbl_main.trust2PK = tlk_located.trust2FK) LEFT JOIN tlk_unableToLocate ON tbl_main.trust2PK = tlk_unableToLocate.trust2FK) LEFT JOIN tlk_bulk ON tbl_main.trust2PK = tlk_bulk.trust2FK WHERE (((tbl_main.dateReceived)<=[cutoffDate]) AND ((tlk_located.locatedTime) Is Null Or (tlk_located.locatedTime)>[cutOffDate]) AND ((tlk_unableToLocate.unableTime) Is Null Or (tlk_unableToLocate.unableTime)>[cutOffDate]) AND ((tlk_bulk.timeStamp) Is Null Or (tlk_bulk.timeStamp)>[cutOffDate]));
I would like a query that lists all dates in a range, and shows the same information for each day listed.
i just had a good talking to. My boss was expecting to show him alot more than I did. Please help me if you can.
I work for a hard drive company. Harddrives are divided up into categories and sub categories. The highest level is "Family." Next is "Model Number," then the lowest is "Product Number." All of these are included in each of the worksheets and they all have different heading names.
The hard drives are stored in many different warehouses that are potentially in 3 different regions (AMERICAS, ASIA, EUROPE)
I am concerned with three excel worksheets that contain all or some of the fields listed above. The different worksheets represent different states of the hard drive: "InTransit" "Customer Shipments" and "Inter Company Shipments"
The goal is to consolidate all of this information into one worksheet.
The other 3 Worksheets represent the data I am pulling from. Ive written a module in access to import all of the excel files into their own individual tables. I've also written some queries to pull the info i need, im stumped though, I'm feeling like I should wipe the slate and start from scratch. What is the best way to go about this?
Hi All. This may be a bit of a strange one, but was wondering if anyone had any ideas. I would like to create a db which is a bit like the directions bit of multimap.co.uk
As per the attached jpg, i would like a db so I can input a starting box and end box, and it would tell me the shortest distance, longest distance, route via boxes etc.
e.g Box A as start and Box F as end. Shortest route is via Box D, longest route via boxes B and C etc.
The db would obviously not for measuring distances between boxes!!!....but thought this may explain it.
I am new in this and would appreciate any help. Here is what i have to do.Have 2 tables ,employees and equipment. People form table1 are signing for equipment from table2.After certain time they turn that equipment and some1 else is getting it. Should i make 3rd table with only signin and signout dates or something else?
Background: I have the foloowing tables tblClient: ClientID (PK) ClientName other client details
tblMachine: MachineID (pk) SerialNumber ClientID (fk to tblClient) other machine details
tblProduct ProductID (PK) ProductName
tblReadout: year_date month_date(pk fld1) day_date(pk fld2) ProductID(fk to tblProduct) MachineID(fk to tblMachine) ReadoutAmount
Question: I would like to build some kind of a form where the user will be able to enter data for readouts (ProductID, MachineID, readoutAmount, year_date, month_date, day_date), but I would like them to only be able to do that, I mean I do not want them to be able to modify any of the other data in the table or even see it, so only adding a record that is it. Also I would like them to be able to enter the ProductName instead of ProductID , how do I go around that ?
I made a form (My_form) with subform (sub_form) and when open main form cursor is in the first (tab = 0) field of the main form, but I want that it is in the first (or desired - for example Name) field of the new record of subform .
Hi I posted a thread in the tables section but two things have made me decide to try again. 1) No one answered my Question 2) I Asked my question in a way that was VERY confusing.
So I'm trying again here. I have a DB that will be used for invoicing clients. Some of the data is variable between jobs, clients & vice versa. Some of the data is recurring.
I have several tables that I need to link. They hold information that is labourious to enter over & over in a spreadsheet so I thought a database would be the answer.
One table is called tbl_Consumables This table has data which varies from time to time but not all data is changed (IE the price of an item may change from month to month. This presents a problem because if I use a table to store the consumables data & the table is linked to an invoice via the ConsumablesID field I can't change any of the consumables data without changing past invoices that should show the old price not the new price.
Basically I can get my head around how the basic design should be set up. I have two main problems. A) Trying to link a days work to an invoice & be able to change data in the future without affecting past invoices and, B) I don't know how to set up the relationships & tables so info is linked.
I have a copy of the DB here. The tables are only minimal fields & data at the moment as I don't want to go to all the trouble of setting this up & then having to change everything.
I have a form to enter RMA data. I need to start my numbering at 4000 without using an autonumber. The ID field is text and cannot be changed. The Customer_Order table is a linked table. A letter is going to be added infront of the ID depending what the user chooses from a combobox. The letter(R,A,C) signifies what type of transaction it is. Here is an example -
R4000 A4001 A4002
Currently there are about 100,000 records in the database but none with an ID between 4000 and 10000. The majority of the records have a letter preceeding the number. Any ideas on how to start numbering at 4000?
Want to use criteria in a date field to query data a week at a time. Open the query and have it ask for week starting MM/DD. Date input will normally use the Monday of each week and expect data back for Monday through Sunday
I am making a database which has a set of lessons which have been booked for a particular date.
What I want to do is be able to have a pop-up box ask you for a date for the start of the week. e.g. I want to find lessons from the week starting 02/03/2007 for 1 week (e.g. 2nd - 9th), so I type in the box "02/03/2007" and it comes up with records from that week.
I have tried this in the criteria box: [Enter date]+7 and =Date([Enter Date])+7
But nothing works. Also, I decided to add a record with todays date, and then use the criteria =Date(), but that didnt work either!!!!
First I will open a form and choose a salesman. Then based on the salesman selected I want to open a recordset and start searching for the last record for the salesman selected. When the record is found some of the information from that record is pulled on the form.