473,388 Members | 1,256 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,388 software developers and data experts.

Pulling multiple queries into one table or query

164 100+
Hello access gurus! I am need of some assitance. I am finally reaching the end or a grueling process. I say grueling, and I am sure its a snap for all of you, which is why I am hoping you all can help....

I have four queries. Two different tables..
three queries are coming from one table (Daily 1) and the other one is coming from the other table (Daily 2)

All of these queries share a common field. "Store Number"

I want the end result to be similar to this http://www.mykesdesigns.com/tblrock1/help/EXCEL.JPG

except 5 more $ Deposited fields...



here are the 4 queries

http://www.mykesdesigns.com/tblrock1/help/ATMDEP.JPG (the ATMDEP field)
http://www.mykesdesigns.com/tblrock1/help/NETSLS.JPG (the NETSLS field)
http://www.mykesdesigns.com/tblrock1/help/DEPOSITS.JPG (the 6 DEP fields)
http://www.mykesdesigns.com/tblrock1/help/ADJTAX.JPG (the ADJTAX field)

I have posted screen caps because I am horrible at explaining things and I think you would appreciate them..


I believe it is relatively simple but I couldn't find anything on google that was what I needed. I am going to continue my search. I do not know too much about sql queries, I know how to use the design view pretty well ^_^

My search continues! I hope someone can help me!
Oct 16 '07 #1
4 2636
FishVal
2,653 Expert 2GB
Hi, there.

Shots are nice but make little sense. You'd better explain it using words. ;)
  • You definitely don't need 4 queries to pull data from 2 tables, 1 query on the tables join would be pretty enough
  • Post [Daily1] and [Daily2] tabels metadata. Here is an example of how to post table MetaData :
    Table Name=tblStudent
    Expand|Select|Wrap|Line Numbers
    1. Field; Type; IndexInfo
    2. StudentID; AutoNumber; PK
    3. Family; String; FK
    4. Name; String
    5. University; String; FK
    6. Mark; Numeric
    7. LastAttendance; Date/Time
  • Explain please what is the reason(s) to have two tables.
  • Clarify please what data you want to pull from the tables: list of fields, filter criteria.
Oct 16 '07 #2
mbatestblrock
164 100+
ALRIGHT!

I think I may have gotten it... Here is what the design view of my final query looks like.

http://www.mykesdesigns.com/tblrock1/help/masterquery.JPG

And here is what it looks like being run.
http://www.mykesdesigns.com/tblrock1/help/result.JPG


Now I am only hung up on one thing! FOR THE LIFE OF ME I couldn't get the dates and currency amounts to layout correctly while importing the external text file. IT WAS NOT HAPPENING...

So does anyone know of way to format the query fields???

the currency was giving me guff on the import like it was trying to add zeros to the end of my number making it in the millions... which would be nice.. but not accurate, I tried moving the decimal spot. I could not get it to work.. same with the dates, If I told to import as a date it would be blank in the field. So I had to tell it to import as text.

any advice?


sorry it is 2AM and I cannot think anymore!!!
Oct 16 '07 #3
mbatestblrock
164 100+
Hi, there.

Shots are nice but make little sense. You'd better explain it using words. ;)
  • You definitely don't need 4 queries to pull data from 2 tables, 1 query on the tables join would be pretty enough
  • Post [Daily1] and [Daily2] tabels metadata. Here is an example of how to post table MetaData :
    Table Name=tblStudent
    Expand|Select|Wrap|Line Numbers
    1. Field; Type; IndexInfo
    2. StudentID; AutoNumber; PK
    3. Family; String; FK
    4. Name; String
    5. University; String; FK
    6. Mark; Numeric
    7. LastAttendance; Date/Time
  • Explain please what is the reason(s) to have two tables.
  • Clarify please what data you want to pull from the tables: list of fields, filter criteria.

HAH sorry I think you posted same time I did. I didnt see this!

the reason I have two tables is because of a ridiculous reason...

I am importing for a fixed width file that is nearly 700 pages long.

there are tons of records in here and each line is a new record.

each record has reference guide to how it is layed out. And it just so happens that there is ONE field that overlapped with another.

and me not knowing anything about queries, and diving too deep into a project like this, I had to kind a way around it.

that is the only workaround I could think of...

so when I import the file, I have to it twice now, another time for just that one field!




======== I hope that made sense??? again 2 am, I work at 8 AM.. LETHAL
Oct 16 '07 #4
FishVal
2,653 Expert 2GB
That doesn't make sense. Go bed. Tomorrow take a look at my questions and try to give relevant answers. This concerns particulary your tables metadata.

Kind regards,
Fish

P.S. I recall your import issue pretty well. ;)
Oct 16 '07 #5

Sign in to post your reply or Sign up for a free account.

Similar topics

4
by: DG | last post by:
Hi, Can anyone advise how to execute multiple statements in a single query batch. For example- update customers set customer_name = 'Smith' where customer_name = 'Smyth'; select * from...
3
by: John Ortt | last post by:
> I have a table of dates in ascending order but with varying intervals. I > would like to create a query to pull out the date (in field 1) and then pull > the date from the subsequent record...
0
by: MHenry | last post by:
Hi, I know virtually nothing about creating Macros in Access. I would appreciate some help in creating a Macro or Macros that automatically run(s) 14 Queries (three Make Table Queries, and 11...
11
by: dskillingstad | last post by:
I've been struggling with this problem for some time and have tried multiple solutions with no luck. Let me start with, I'm a novice at Access and I'm not looking for someones help to design my...
13
by: MLH | last post by:
I have tblVehicles, tblOwners, tblProxies, tblLienholders. In the vehicles table are and identifying owner and proxy (generally an attorney). Vehicles table is child table to tblOwners and...
4
by: Dave Edwards | last post by:
I understand that I can fill a datagrid with multiple queries, but I cannot figure out how to fill a dataset with the same query but run against multiple SQL servers, the query , table structure...
7
by: =?Utf-8?B?QVRT?= | last post by:
HOWTO Run multiple SQL statements from ASP/ADO to an Oracle 10g. Please help, I'm trying to write an ASP page to use ADO to run a long query against an Oracle 10g database, to create tables,...
11
by: shriil | last post by:
Hi I have this database that calculates and stores the incentive amount earned by employees of a particular department. Each record is entered by entering the Date, Shift (morn, eve, or night)...
14
by: Supermansteel | last post by:
My team at work uses Cognos to run multiple queries to pull in data. Then they take that data and import into Access and then usually run an Append Query to run a RND function to pull out a few...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.