General :: Creating Distinct Transactions

Jun 24, 2013

I need to create distinct transactions for each invoice, so that if the static data changes, such as rates of charge, it will not automatically update any history, where a historic rate has been charged.My current thinking is that I create a table and effectively archive all invoices that have been created, as they are produced.

View Replies


ADVERTISEMENT

General :: Calculating Stock Level For Spare Parts From Transactions

Jun 19, 2012

I am trying to calculate the stock level for my spareparts. I am aware of that I am not to update the stock level in my table but calculate the total from the transactions.

View 9 Replies View Related

Need Distinct Records Of Whle Table But Distinct On One Field

Sep 15, 2006

Hi, Wish if some one could help me ASAP.
I have a table which contains name, tel, email
i need to import only records which have distinct email.
I do need need to import data of all three fields but only which has distinct email.
As there are number of record which are duplicate.
They have different names but same email.
So i need to condition only for distinct email but dump the data in a new table with all three records.
so same names can have different email.
but same email can't have duplicate email.
So need only records which have distinct email.
Please help .......

View 1 Replies View Related

General :: UPDATE Field In Table Based On DISTINCT Values

Mar 12, 2013

Below is a sample of the table with the data. I manually added the 1 and 0 to the hc_Year field. However, I would like to create an Update query that will add a 1 to the hc_Year if its the first instance of PIDM & regsYear and add a 0 to the records that are not the first instance.

PIDM | regsYear | hc_Year
52 | 2009 | 1
52 | 2010 | 1
201 | 2007 | 1
201 | 2007 | 0
201 | 2007 | 0
201 | 2008 | 1

View 6 Replies View Related

General :: Populate List Box With Distinct Months From Date Field

Nov 27, 2012

I have a table of data which includes a date field and also various other fields which may or may not be filled with data.I'm trying to populate a listbox with the months for which this data is missing (a separate macro will then loop through these months to fill the missing data) But I only want each distinct month to populate the listbox - not each individual date.

Code:
strSQL = "SELECT DISTINCT month([EntryDate]), year([EntryDate]) FROM [SampleTable] WHERE [ValueField] Is Null"
Me.lstSampleListBox.RowSource = strSQL

I want to return the month in <mmm yyyy> format.

View 2 Replies View Related

Distinct Rows From Non-distinct Data?

Oct 10, 2005

I have data which consists of:

xxxxx123 A.Nother 123456
xxxxx123 B.Jones 123457
xxxxx456 D.Smith 123458
xxxxx456 Z.Zephir 123489

How would I ensure that the query returned only unique rows (where column 1 is unique) based on the first alphabetical record of column 2?

Any ideas?

View 1 Replies View Related

General :: Creating A Database For Creating Quotations

May 20, 2015

I am creating a database for creating quotations. The quotation number is generated using the date, for example the first quote today would be quote number "05202015-1" because it is the first one today. The next quote today would be quote number "05202015-2" and so on. Is there a way to make access automatically generate these quote numbers based on the date?

View 3 Replies View Related

Transactions In Access

Aug 14, 2005

Hi, folks.

I have to write a PHP web front-end to a client-server MS Access applicatin, and I think I've hit a stumbling block.

I use ADOdb as my db abstraction layer, and it has transaction functionality built in. I've tried it with Access, and while according to the output of the code the transaction has worked, I see clearly that it has not worked.

If I insert an intentionally malformed statement as part of the transaction, none of the other queries are rolled back upon the failure of said transaction.

I know this is an Access forum, not a PHP forums, but I've gotten zero response to this post on PHP forums.

Does anyone know if there's a way I can implement transactions for Access via PHP?

Cheers and thanks very much in advance.

Pablo

View 1 Replies View Related

Counting Transactions

Sep 17, 2007

Hi there,

I have one table, called tblTransactions, which contains records on security market transactions. For each buy and sell order, respectively it contains one dataset with columns Date, Ticker (i.e. the unique identifier of each security), Quantity (positive for buy, negative for sell orders) and Price (at which the trade was executed).

The following SQL query code gives me then the composition of my security portfolio as per any arbitrarily chosen date (here 1/10/2007):


SELECT [tblTransactions].[Ticker], sum([tblTransactions].[Quantity]) AS TotalQuantity
FROM tblTransactions
WHERE [tblTransactions].[Date]<=#1/10/2007#
GROUP BY [tblTransactions].[Ticker]
HAVING sum(tblTransactions.Quantity) >0
ORDER BY [tblTransactions].[Ticker];


For instance, for some trades like the following...


Data --- Ticker --- Quantity --- Price
01/01/07 --- AAA --- 50 --- $50
01/01/07 --- BBB --- 25 --- $75
01/15/07 --- AAA --- 30 --- $60

...it results in the following query results:

01/10/07:
Ticker --- TotalQuantity
AAA --- 50
BBB --- 25

01/20/07:
Ticker --- TotalQuantity
AAA --- 80
BBB --- 25

However, I would like to add a column to this query, which gives me the number of trades for each particular stock. For instance, the query result based on the sample data above should look like follows as per 01/20/07:

Ticker --- TotalQuantity --- NumberOfTrades
AAA --- 80 --- 2
BBB --- 25 --- 1

I have absolutely no idea how to achieve that. I would be very happy for any suggestions.

Best regards,
JapanFreak

View 4 Replies View Related

Transactions In Access XP

Nov 23, 2004

I am trying to run a transaction in my databases and I’m having problems with rollback. I have an append query and a delete query that I’m trying to run Just a test I begin the transaction, run the queries and then rollback the transaction. For some reason the rollback isn’t working. Please look at my code and let me know what I’m doing wrong. Are transactions not available in DAO? Also, how do you tell if all records were updated – How do you know when to Rollback?


Sub ArchiveRecords()
Dim db As DAO.Database
Dim qdfArchive As QueryDef
Dim qdfDel As QueryDef
Set db = CurrentDb
Set qdfArchive = db.QueryDefs("qry0201ArchiveLayoffs")
Dim cnn As Connection
Set cnn = CurrentProject.Connection
Set qdfDel = db.QueryDefs("qry0202DelArchiveLayoffs")
cnn.BeginTrans
qdfArchive.Parameters(0) = 1
qdfArchive.ExecuteqdfDel.Parameters(0) = 1
qdfDel.Execute
cnn.RollbackTrans
End Sub

View 1 Replies View Related

SQL For Financial Summary From Transactions

Oct 20, 2005

I am working on a financial integration system that receives lists of financial journal transactions from several accounting packages.

I import and sumarise the transactions and end up with a transactions table like the one below. I now want to produce an Accounts summary (by period) table. I am trying to figure out how to do this just using SQL.

I do not want to use record by record VB because it is slow and I have a million+ records.

Can anybody help ?

Transactions Table (input)

Account Period Amount
1011100
1015 100


Account Summary (desired output)

Account Period Opening Movement Closing
101 10100100
10121000100
10131000100
10141000100
1015100100200

PS I need to run on Access and SQL Server

View 1 Replies View Related

Need Sample Database For Stock Transactions

Jan 28, 2008

Hi,

I'm in over my head with something I've been asked to do at work as my access skills are pretty basic.

I need a sample database containing PRODUCTS and SUPPLIERS, that lets you book IN stock received from the supplier (and adds to the stock level) and lets you book OUT stock issued to staff (and reduces the stock level)

I'll have a go at reorder levels, form design, stuff like that myself, but I'm having trouble with these very basic requirements.

Does anyone know of a sample database that I can download to learn some of this from?

View 2 Replies View Related

Running Calculation Based On Previous Transactions

Jul 12, 2005

I am building an application for a small clinic. In the interests of good database design, I don't want to be storing numbers that are derived by calculation.

A patient with insurance will have a deductable that will be entered into a field on their first (ms access) transaction form.

A calculation will put the remaining deductable into another field. No problem.
However, the NEXT visit has to look back to find previous transaction records, again perform the initial calculation and then perform another for this transaction, and again the next time and the next until the deductable reaches zero.

Additionally, since I'm not storing these values, if I pull up an old transaction form, that form has to re-perform the calculation ONLY on transactions from that date and earlier. It must not reflect visits that took place later.

So, this field must query tblTransactions, filtered by the name of the patient (a combo box called tblTransactions.Patient_Name that looks at tblContacts), the transaction date/time (stored in two date/time fields, cleverly named tblTransactions.Date and tblTransactions.Time), and the total deductable value stored in a field called tblTransactions.Deductable.

As someone who has never coded anything more complicated than DOS batch files, I'm at somewhat of a loss as to how to go about this.

Any assistance, code-wise and which Property value to put it in would be MOST appreciated.

View 1 Replies View Related

Making Transactions With Multiple Products (Diagram Inside)

Mar 21, 2008

Hey people, hows it going? Quick question

I am creating an EPOS system for a bookstore and I have a many to many relationship between the transactions table (tbl_transactions) and the products table (tbl_products) using a link table (tbl_linktblproductstransac). The below diagram shows what i mean below:

http://img512.imageshack.us/img512/3246/relationnshipswd9.jpg

I made it many to many because 1 transaction can have many products on it and 1 product can be on many transactions.

Now what I need to know is how will i make records with more than one product on one transaction (in the table itself or in a transaction form). I would really appreciate if someone could help. Thanks :) and have a good Easter

View 2 Replies View Related

Show Certain Records (eg: Unpaid Transactions) As A Different Colour In A Listbox

Nov 30, 2006

i think this post may benefit others because to me it seems like a good idea,

a listbox displays 2 fields from your database

job table
id (autonumber primary key)
pay (text)

here are 5 records,
1,paid
2,paid
3,paid
4,unpaid
5,unpaid

if you make a form with a listbox showin these records..

is there a way to make the unpaid records appear as red?

View 9 Replies View Related

Modules & VBA :: Calculate Median Value For Group Of Transactions Within The Same Industry?

Oct 15, 2013

I am using the code below to evaluate values for each transaction to determine the median:

Function MedianF(pTable As String, pfield As String, pgroup As String) As Single
'*******************************************
'Purpose: Return median value from a recordset
'Inputs: ? medianF("Values", "Industry") <enter>
'Output: results are currently incorrect
'*******************************************
Dim rs As Recordset
Dim strSQL As String

[code]....

The code generates median results based on the value but not the correct ones, as I check results in Excel using the Median function. I need to see the median for the transactions within the same industry and I do not know how to do that . Below are some sample transactions including the Industry, Value, mymedian (which the current results based on my code) and the expected median result (which I calculated in Excel based solely on the transactions listed here). Note that mymedian results listed in the 3rd column are determined using the complete data set (over 2000 transactions). I only included a few sample transactions below to show that I am currently getting 2 different median results: 44.62 and 50.82. Also be aware that I do not want to evaluate any zero value transactions, which I believe I am handling in the strSQL line above where I indicate <>0 . I need to see a Median result for each industry and the result should be the same for all transactions within the same industry.

Industry Value mymedian Expected Median
Aerospace 18.01 50.82 40.45
Aerospace 53.02 50.82 40.45
Aerospace 109.18 50.82 40.45
Aerospace 61.54 44.62 40.45

[code]....

This is how I am passing the values from the query to the module, passing the value of Period2 if Period 1 = 0, else passing Period1:

mymedian: IIf([Period1]=0, medianF("qry_My_Query","Period2","Classification_I ndustry"), medianF("qry_My_Query","Period1","Classification_I ndustry"))

View 14 Replies View Related

Tables :: Relating Transactions With Rate Master Table

Jan 28, 2013

I am using Access 2007 and have inherited a database. It has linked tables of Excel spreadsheets that are information extracted from our main system. The user wants developing a much faster and customized approach to billing the customer based on payroll related information.

There is a table of payroll billing transactions and it has the following record lay-out,

job_num, employee number, employee name, union group, rank, regular hours, overtime hours, other hours, trans_date, seq_num

6430, 2301, john doe, 1, F, 8.0, 0.0, 0.0, 12/01/2012, 254333

On December 1st John Doe worked 8.0 regular hours as a pipefitter foreman on job number 6430 and this is record (sequence) number 254333.

There is another table that defines the union group. I am not concerned with this information at this time. The seq_num is a sequentially and uniquely assigned number given to each billing record in the main system.

There is also a Rate Master table and it has the following record layout,

job_num, union group, rank, regular_billing_rate, overtime_billing_rate, other_billing_rate

I am struggling as to how to relate these two tables so that I can develop some queries from it.

View 2 Replies View Related

Queries :: Time Query - Show Transactions For Particular Session

Jul 20, 2015

I have a pop up reports tied to my form so the usere can press the see list report of all the equipment they just scanned in or out of the building. I am useing the Date/Time data type (General Date) What I would like to get out of the query is when the user clicks the button it will show all entries from the time right before the button is pressed AND through 5 minutes earlier. (That would be the time that the user would of started scanning the equipment.

This is my current criteria : Between Now() And Date()

This is returning all transactions for the day. I really only want all transactions for that session.

View 3 Replies View Related

Queries :: Keeping Records Of GST Transactions - How To Do Calculations In Query

Apr 5, 2013

I am trying to keep records of GST transactions.

I have a problem in figuring out how to do calculations in a query.

How to have the calculation in the attached MDB and Document for field #105_SubTotal and the field #115_PaymentEnclosed.

View 7 Replies View Related

Queries :: Adding Sequence Number To Transactions Based On Date And Unique ID

Jul 29, 2014

I have a set of transactions with a Unique ID field and a date. I want to add a field based that gives me the sequence of events for each Unique ID in order of when it happened.

For example, if customer X has 6 transactions, the sequence field would have a number (1-6) in each record that corresponds to the order in which those transactions occurred. The first transaction would have the number 1, the second would have the number 2 and so on.

View 3 Replies View Related

Queries :: Products Form - Listbox To Show Recent Inventory Transactions

Apr 3, 2014

I have a products form, we are a manufacturing company, with a listbox to show recent inventory transactions. This is based on a query which shows all transactions with the current part id, and that all works well and fine.

The problem is, I would like to limit this query to show only the last 10 transactions in the listbox and not make it editable, ie not enabled. I set the show only in query design view to 10 and it says in the sql statement select top 10, however, the listbox consistently shows all related records. What am I missing?

View 8 Replies View Related

General :: Creating A Profile / Database?

Nov 4, 2014

is there a way to create a profile on each person on my database, to show their contact details and whether they've made a purchase from me before, or must I literally just make a table entering each individual person and purchase?

My boss (in another job) showed me very quickly an extremely old database one of his old employees had made for him years ago containing all of his clients, each shown individually, and he was able to click through each one, and each window showed the client's name, contact details, personal details, etc. and he just had hundreds of entries for all of his clients and was able to scan through each individual one. I am 99% sure he said it was on Microsoft Access that he'd done it.I just want to monitor how many of mailing list subscribers have also made purchases and whatnot, as I do rewards for them, and it'll be much easier to view each person's profile and the orders they've made than have to scan through a table to find each separate order?

View 6 Replies View Related

General :: Creating A Button Used To Sent Email

Jul 4, 2012

I'm trying to create a button who is able to send a email with an attachment.The attachment will be all the time the same file.The email address to sent to is one of the field of the database.I need a copy sent in my email address as well.

View 9 Replies View Related

General :: Creating New Record After Update

Mar 13, 2014

I have a table called [Tasks] which has the following relevant fields:

[Task ID]
[Location]

I have a form that people use to create new tasks and update current ones. Location on the form is a combo box where people can pick from 5-6 different locations.

What I want:

After someone selects a new location from the combo box and changes the task location, I want to create a new record in a table called [Task Progress] with the [Task ID] of the task whose location was changed, the new [Location], and the [Date] and [Time] it was changed. It would look like

Code:
[Progress ID] [Task ID] [Location] [Date] [Time]
1 5 Station 1 1/1/2011 12:13:01
2 8 Station 2 1/3/2011 01:53:29
3 5 Station 2 1/5/2011 11:13:05
4 5 Station 3 1/6/2011 12:35:22

What should I put in the AfterUpdate event for the [Location] combobox to make the above happen?

Note: All my tables are ODBC linked to SQL Server (can't use data macros).

View 1 Replies View Related

General :: Creating Emails Through Word?

Jul 23, 2012

is there a way to create an email through word and say your current balance is £1000.

i thought that as this is an office app then it must be possible. could it be something like

=DLookUp("c:UsersChrysalisDesktopDatabase.accd b[LoyaltyPoints]","tblClientDetails","EmailAddress= " & Mail Recipient)

View 1 Replies View Related

General :: Creating Report Or Query

Nov 9, 2014

I am quite new to MS access and started to develop a small database for my practice. I have made four tables that are for Patient details, their doctor detail, their problem and their treatment. I have successfully created form to enter the data.However I an unable to proceed, now I want to create a discharge letter which will be addressed to the doctor (based on the tables described above)

I want to make this in a way that if I enter the patient details i-e date of birth, ID and / or name a letter is created based on the tables above. I also want this letter to be saved for future use. how to design that letter and should it be a query or report.

View 6 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved