|
|
|
Displaying records that have one of two fields equal to Master Field
Wed, 17 Dec 2008 10:48:44 -0800 (PST)
I have both parents and children in a table (with unique ID numbers).
I am making a form that will display a parents name and then all
children related to that parent. In order to do this, I made two
fields for each child named "Relationship1" and "Relationship2" that
contain a parent's ID number.
I can succ ...
|
Group by prefix characters, then sum another column
Wed, 17 Dec 2008 10:32:06 -0800
Does any one know how to use the Totals feature to group by the first
character in a field, then sum the values in another column that share a
common prefix? I need to do this in a query.
I have one column that has codes such as P001, P002, P003, U001, U002, U003.
I want to group all of the 'P' records ...
|
MS Access 2002, Select...INTO...Excel?
Wed, 17 Dec 2008 08:35:37 -0800 (PST)
Hi,
Believe it or not, we're still using MsAccess 2002 here. Anyways, we
use it in order to query a SQL Server DB via an ODBC bridge. We run
our queries and then export the results to Excel for another group.
Question: I'd like to know if the query itself could export the
results directly to excel (or any ...
|
To Sort or not To Sort (Speeding up Queries)
Wed, 17 Dec 2008 08:22:07 -0800
Hello all,
I had a wonderment this morning whilst designing a query.....
Case) You have 6 fields you're selecting from a table:
tbltest.field1, tblTest.field2, tblTest.field3, tblTest.field4,
tblTest.field5, tblTest.field6
Example)
Private Sub cmdButton1_Click()
Dim strSQL AS String
Dim rs ...
|
count within a given range
Wed, 17 Dec 2008 08:16:27 -0800
I have a table of Customers that are assigned a Market ID and a second table
that groups the Market IDs by a range and assigns them to an Industry
description.
For example:
Cust Table
Customer Name, Market ID
Market Table
Market IDs 1000 thru 1199, Industry1
Market IDs 1200 thru 1399, Industry2 ...
|
Number of days not calculating correct in an iif expression
Wed, 17 Dec 2008 07:58:00 -0800
I am trying to calculate the number of days between a hard date (7/1/2008)
and a calculated field (newstepdate) only if a field (step < 7) and
(newstepdate < 7/1/2009). the below code works except when month is 10 11
or 12. I am guessing this may be some type of converting problem but I
cannot come up wit ...
|
Top Clause with GROUP BY clause?
Wed, 17 Dec 2008 07:34:28 -0800
Hi,
I have a simple table with only 3 fields
Product Category USD_sales
I am looking to get the 5 products that are the most sold from each category.
Can I do that from 1 query or do I need 5?
Many thanks,
Dan ...
|
|
|
Crazy field alias- possible?
Wed, 17 Dec 2008 07:12:28 -0800
Don't ask why...format needs to stay this way for a graph.
I have fields in the table from a s/s: BBL2007 BBL2008 KWH2007 KWH2008...
I want to show this current years' BBL (currently BBL2008, but next year
will change to BBL2009) and last years' BBL (BBL2007...), but if you set an
alias, like ThisYrBBL: "[" & ...
|
Diffciult query
Wed, 17 Dec 2008 15:01:29 GMT
I have this query:
SELECT DISTINCT Q.[creation_date], Round(Now()-Q.[creation_date],0) AS
Diferenc,
Q.[Nº Siniest], Q.Asunt, Q.Usu, Q.Obs
FROM [HISTORIC] AS Q
WHERE (((Q.[creation_date])=(SELECT MAX([creation_date])
FROM [HISTORIC] As T
WHERE T.[Nº Siniest] = Q.[Nº Siniest])) AND ((Q.Asunt) Not Like
"Au ...
|
Query for two fields
Wed, 17 Dec 2008 06:41:39 -0800
In a table are fields QtyYear & QtyAmount. QtyYear contains the year (2007,
2008) for the donated amount (QtyAmount). But if no donation for that year
then no record.
I wanted to pull donors who gave in both 2007 & 2008. Not including folks
who gave in just one of those years. I've tried:
SELECT D.Donor
FRO ...
|
|
|