Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Search results for query: *

  1. maxflitom

    Backing up an Access datatabase to span multiple disks

    Thanks vbSprgrmr, I searched this site for Backup but not compression. Hopefully I will be able to find some code which I can incorporate in my app. I have error handlers in place for the errors. When the app terminates, I call a backup routine which uses the CompactDatabase of JRO. In this...
  2. maxflitom

    Backing up an Access datatabase to span multiple disks

    Hello Tek-Tips, My app currently uses the JRO.JetEngine CompactDatabase method to backup my Access 2002 database. I have two concerns. 1. My first concern is that when by db gets too large to fit on the removable media, it will not allow the file to span multiple disks. 2. My second concern...
  3. maxflitom

    Using Variables In SQL Select Statement

    shirverb, Thank you for responding. Maybe I did not word my question properly. I wanted to create input variables within my SQL statement to be used withing the SELECT Statement. I am writing a SQL statement that will require several input variables in order to retrieve the requested results...
  4. maxflitom

    Using Variables In SQL Select Statement

    SkipVought, Thank you for responding. I dug a little further and found what I am looking for. Access has a Parameters keyword used to define input parameters. The syntax for this question would be: PARAMETERS @Date1 DATE, @Date2 DATE; SELECT Revenue FROM MyTable WHERE Date BETWEEN @Date1 AND...
  5. maxflitom

    Using Variables In SQL Select Statement

    Hello Tek-Tips and thank you again for taking the time to read my question. Is there a way to declare a variable in a SQL Select statement which will allow me to assign through VB6. I am generating a SQL statement which uses 4 dates as parameters. However these 4 dates are needed several times...
  6. maxflitom

    SQL Help Summarizing Totals in Table

    rac2, Man, I tried the JOIN thing before messing with Duane's code and could not get it to work. I can follow your statements easier then Duane's and wanted to use your's. I made some modifications to the Queries and you SQL and came up with this which gives me the correct results. SELECT...
  7. maxflitom

    SQL Help Summarizing Totals in Table

    Duane, I GOT IT, don't mean to yell but it works and it works well. Just FYI I will post my modified code for reference if anyone else may need help with the same situation. On November 2, I am voting for dhookom for President! Thank you so very much, you made my day!!! My Code: SELECT...
  8. maxflitom

    SQL Help Summarizing Totals in Table

    dhookom, Man I really appreciate your help with this. We are almost there. I made some minor modifications to your code, just missed some "(", got some Syntax errors. I fixed them and the MTD total are correct...yea...However the RoomsToday are all 1 and the RevenueToday for all is 0. How can I...
  9. maxflitom

    SQL Help Summarizing Totals in Table

    Yes, it should return 9 rows, I simlified the SQL statement for my question. I typed your SQL statement as you have it and it returns 1 as RoomsToday. Here is my statement: SELECT RevenueDetail.Rooms, RevenueDetail.Revenue, MarketSegments.MarketSegmentID, MarketSegments.MarketSegmentName...
  10. maxflitom

    SQL Help Summarizing Totals in Table

    rac2 and khookom, I tried both statements I get the correct results using rac2's approach, however, I should recieve 9 rows and I get 81, a cartesean join. dhookom, I see where your code is going, however I must sum the Revenue and Rooms fields and I do not see these field names in your SUM()...
  11. maxflitom

    SQL Help Summarizing Totals in Table

    Thank you rac2 and dhookom, I will try out both SQL statements and I will post my results when I get it to work. Sorry it took me so long to respond, I was out of the office. Thanks Again! Tom (maxflitom)
  12. maxflitom

    SQL Help Summarizing Totals in Table

    Hello Tek-Tips, My question today is I wish to extract info from a Table (Access 2002) called (RevenueDetails) which includes the Fields (Rooms) and (Revenue). I wish to display today's Rooms & Revenue and month to date Rooms & Revenue in one statement. I am having some difficulty doing this...
  13. maxflitom

    SQL getting a cartesean Join

    Golom, Thanks for the post. I have been a little out of it for a few days which is why it has taken me so long to reply. I will let you know how it works. Thanks Again!!! Tom (maxflitom)
  14. maxflitom

    SQL getting a cartesean Join

    Hello Tek-Tips, I have struggled far too long on my attempt to summarize data in my Access Database. I wish to code a SQL statement that will total all of my customer's revenues and group them by CustomerName. Here is the structure of my database: Events Table: (one Event to many EventDetail...
  15. maxflitom

    Help on SQL getting a cartesean join

    golom, Sorry for the late response. The reason I added the EventID in the Group By clause is I get an error when I run the query that states the the EventID was not include EventID as part of the aggregate expression. Here is SQL on a Union Select which returns the correct results, however...
  16. maxflitom

    Help on SQL getting a cartesean join

    golom, We are almost there. The only issues I have are in your SQL, I had to add the Events.EventID to the Group By. When I do this, instead of getting just one total for each customer, I get the same number as there are items in the EventDetail Table. I tried some variations and still cannot...
  17. maxflitom

    Help on SQL getting a cartesean join

    johnwm, I have already attempted that route. All I want my report to accomplish is a list of customers and the total spent within a date range. If I can accomplish this in one SQL string, it seems that it would be the most efficient. Tom (maxflitom)
  18. maxflitom

    Help on SQL getting a cartesean join

    Thanks Golom, I will try it. I will send you a response and a checkmark when I get it to work. Tom (maxflitom)
  19. maxflitom

    Help on SQL getting a cartesean join

    JeffTullin, Sorry I should have been let you know what I needed it for. I am using VB6 and wish to generate a DataReport using the Data Report Designer. Didn't want to make my question longer than it should have been, Tom (maxflitom)
  20. maxflitom

    Help on SQL getting a cartesean join

    Hello Tek-Tips, I am attempting to summarize customer totals into one amount from two different Access Tables, the Events and EventDetail Tables. The Sum() function from the EventDetail table returns the correct result, however, the amounts returned from the Events Table are duplicated by the...

Part and Inventory Search

Back
Top