Solved

Now I got the hard question out of the way lets try this

Posted on 2006-07-09
30
319 Views
Last Modified: 2008-03-17
I have learned how to get the sum of the total records in a query, now I need to know how to get the total for each record in a repeat region.   my table has a total column at the end of each row.  so with the query below how do I write it to give me the total for each record by its self.

By the way, I could have not even come close to building the database I have now if it wasn't for the help I have been getting from you all.   I am forever greatful.

SELECT (paymaker_quanity * paymaker_unit_price) as Total
FROM paymaker, invoice_my_custom
WHERE userid = 'varuserid' AND pmdate >= 'varpmdate1' AND pmdate <= 'varpmdate2' AND company = Val('varcompany')
0
Comment
Question by:budgilbert67
  • 13
  • 10
  • 5
  • +1
30 Comments
 
LVL 3

Expert Comment

by:cdemir
ID: 17069506
hi,

can you post your tables fields and sample data of your needing.
0
 
LVL 44

Expert Comment

by:Arthur_Wood
ID: 17069938
1) how are paymaker and Invoice_my_custom related?  What field in each table holds the SAME value, to tie records from each table together?

as for total by region:

SELECT region,(paymaker_quanity * paymaker_unit_price) as Total
FROM paymaker, SELECT (paymaker_quanity * paymaker_unit_price) as Total
FROM paymaker, invoice_my_custom
WHERE userid = 'varuserid' AND pmdate >= 'varpmdate1' AND pmdate <= 'varpmdate2' AND company = Val('varcompany') and Paymaker.Field1 = invoice_my_custom.Field1
Group By Region

AW
0
 
LVL 75

Expert Comment

by:Anthony Perkins
ID: 17070266
>>I am forever greatful.<<
Than please acknowledge it by following up on the following question, as it is now considered abandoned:
http://www.experts-exchange.com/Databases/Microsoft_SQL_Server/Q_21878834.html

Thanks.
0
 

Author Comment

by:budgilbert67
ID: 17072196
Arthur Wood,
This query doesn't work.  
0
 
LVL 44

Expert Comment

by:Arthur_Wood
ID: 17072280
what are the fields in the two tables (paymaker and invoice_my_custom) that relate the two together?

Can you show the field names of the two tables?  And some representative data?

When you say it doesn't work - do you get an error message, or do you get the wrong results, or do you not get any results at all?

AW
0
 

Author Comment

by:budgilbert67
ID: 17072339
I get an Error Message in the From Clause
0
 

Author Comment

by:budgilbert67
ID: 17072368
SELECT (paymaker_quanity * paymaker_unit_price) as Total
FROM paymaker
WHERE userid = 'varuserid' AND pmdate >= 'varpmdate1' AND pmdate <= 'varpmdate2' AND company = Val('varcompany')

Invoice_my_custom isn't needed in this query, sorry guys.   This is the only table's and fields needed for this query
0
 
LVL 44

Expert Comment

by:Arthur_Wood
ID: 17075297
what are the fields in the paymaker table?

try this:

SELECT region, Sum((paymaker_quanity * paymaker_unit_price)) as Total
FROM paymaker
WHERE userid = 'varuserid' AND pmdate >= 'varpmdate1' AND pmdate <= 'varpmdate2' AND company = Val('varcompany')
Group by Region

AW
0
 

Author Comment

by:budgilbert67
ID: 17080312
AW, I am getting a error, to few parameters 1 expected, I think that the server is looking for a field called region in my Access database.
0
 

Author Comment

by:budgilbert67
ID: 17113045
I am still hoping for an answer to my question.  could some please try and figure this out for me
0
 
LVL 75

Expert Comment

by:Anthony Perkins
ID: 17113219
Post the structure of your paymaker table.
0
 
LVL 44

Expert Comment

by:Arthur_Wood
ID: 17113997
you originally asked:

"I have learned how to get the sum of the total records in a query, now I need to know how to get the total for each record in a repeat region"

what are you refering to when you say 'repeat region' - I assumed that you meant you had a field REGION in your table.  Enlighten me, as to what it was you wanted to be able to do.

AW
0
 

Author Comment

by:budgilbert67
ID: 17114491
<%
' Show IF Conditional region3
  If (Recordset1.Fields.Item("repeat_region").Value) = "retail" Then
%>
                  <table width="100%" border="0" align="center" cellpadding="0" cellspacing="0" id="field3">
                    <tr>
                      <td width="10%" class="optionheader">Quantitiy:</td>
                      <td width="9%" class="optionheader">Item:</td>
                      <td width="32%" class="optionheader">Discription:</td>
                      <td width="11%" class="optionheader">Taxable:</td>
                      <td width="19%" class="optionheader">Unit Price: </td>
                      <td width="11%" class="optionheaderend">Total:</td>
                    </tr>
                    <%
While ((Repeat1__numRows <> 0) AND (NOT Recordset3.EOF))
%>
                      <tr>
                        <td class="invoicerows"><%=(Recordset3.Fields.Item("paymaker_quanity").Value)%></td>
                        <td class="invoicerows"><%=(Recordset3.Fields.Item("unit_name").Value)%></td>
                        <td class="invoicerows"><%=(Recordset3.Fields.Item("pmnote").Value)%></td>
                        <td class="invoicerows"><%=(Recordset3.Fields.Item("paymaker_taxable").Value)%></td>
                        <td class="invoicerows"><%= FormatCurrency((Recordset3.Fields.Item("paymaker_unit_price").Value), 2, -2, -2, -2) %></td>
                        <td class="invoicerowsend">&nbsp;</td>
                      </tr>
                      <%
  Repeat1__index=Repeat1__index+1
  Repeat1__numRows=Repeat1__numRows-1
  Recordset3.MoveNext()
Wend
%>
                    <tr>
                      <td class="endrow">&nbsp;</td>
                      <td class="endrow">&nbsp;</td>
                      <td class="endrow">&nbsp;</td>
                      <td class="endrow">&nbsp;</td>
                      <td class="endrow"><div align="right">Sub Total:</div></td>
                      <td class="optionheaderend"><%= FormatCurrency((sub_total.Fields.Item("Total").Value), 2, -2, -2, -2) %></td>
                    </tr>
                    <tr>
                      <td>&nbsp;</td>
                      <td>&nbsp;</td>
                      <td>&nbsp;</td>
                      <td>&nbsp;</td>
                      <td><div align="right" class="style4">Tax:</div></td>
                      <td class="optionheaderend"><%= FormatCurrency((retail_tax.Fields.Item("Total").Value), 2, -2, -2, -2) %></td>
                    </tr>
                    <tr>
                      <td>&nbsp;</td>
                      <td>&nbsp;</td>
                      <td>&nbsp;</td>
                      <td>&nbsp;</td>
                      <td><div align="right" class="style4">Total:</div></td>
                      <td class="optionheaderend"><%= FormatCurrency((retail_tax_sale.Fields.Item("Total").Value), 2, -2, -2, -2) %></td>
                    </tr>
                  </table>
                  <%
  End If
' End Conditional region3
%>
0
 
LVL 75

Expert Comment

by:Anthony Perkins
ID: 17114543
Is there any chance you can post the structure of your table, some sample data and the desired output?
0
What Is Threat Intelligence?

Threat intelligence is often discussed, but rarely understood. Starting with a precise definition, along with clear business goals, is essential.

 

Author Comment

by:budgilbert67
ID: 17114578
The above is the structure of my table.
if your asking about my Access DB table it is like this.

paymaker_quanity    "text field"
paymaker_unit_price    "text field"

So, what I am trying to do is make the repeater show the total of (paymaker_quanity * paymaker_unit_price) for every row in a new column called total.   I am showing the SUM(total) at the bottom of the table, which I already know how to do.   All I need to learn how to do is show the caluculation for each record by it's self in the repeater.   I hope the this is more understandable.   Thanks
0
 
LVL 75

Expert Comment

by:Anthony Perkins
ID: 17114636
Try something like this:

SELECT Val(paymaker_quanity) * Val(paymaker_unit_price) as Total
FROM paymaker


Since you have not included the data type for the rest of the fields (userid, pmdate, company), let alone sample data, I will not speculate as to what should go in the WHERE clause or the rest of the SQL statement for that matter.
0
 

Author Comment

by:budgilbert67
ID: 17114704
acperkins, this gives the calculation for the first record in every column, please try again
0
 
LVL 75

Expert Comment

by:Anthony Perkins
ID: 17114722
>>acperkins, this gives the calculation for the first record in every column<<
No that is not correct. It produces the calculation for every record, based on the values of the paymaker_quanity and paymaker_unit_price columns.

>>please try again<<
Sorry, until you can provide valid feed back as requested, I have no further interest in contributing to this thread.

I wish you the best of luck.
0
 

Author Comment

by:budgilbert67
ID: 17115472
acperkins, I guess I do not know exactly what information you are looking for.   Mabye there is a better way of getting this value, like adding a total field to my database, and doing the calculation in the insert, or update transaction.  Let me know what you think.   Thanks for you help so far.
0
 
LVL 75

Expert Comment

by:Anthony Perkins
ID: 17116127
>>I guess I do not know exactly what information you are looking for<<
Ok.  Let's try it again:
"Is there any chance you can post the structure of your table, some sample data and the desired output?"

The "structure" you posted only contained 2 fields.  There was no sample data, let alone desired output.
0
 
LVL 44

Expert Comment

by:Arthur_Wood
ID: 17116328
How many fields (ALL OF THEM) are there in your table, and what are the data types?  ANd please show us some sample data (ALL OF THE FIELDS) from your table.  Is that clear enough?

AW
0
 

Author Comment

by:budgilbert67
ID: 17116418
MS ACCESS TABLE: paymaker
userid  AUTO NUMBER
pmdate   text   yyyymmdd
pmaddress   text
pmnote   memo     discription
pmtype     text       Install, service, back charge etc.
paymaker_quanity   text      1,2,3,4
paymaker_unit_price   curancy   12.99
record_date  text   =Date()

Table on page:
quantity: 1,2,3 etc.    item: Item number taxable:  Yes, No discription: momo  unit price: currancy

Hope this is enough info  
0
 
LVL 75

Expert Comment

by:Anthony Perkins
ID: 17117524
>>Hope this is enough info   <<
I am afraid not.  We have repeatedly asked you for sample data and the desired output, because to be quite frank your requirements in your original question are not sufficient.  For example you state: "I have learned how to get the sum of the total records in a query, now I need to know how to get the total for each record in a repeat region".  We need a definition of region using the columns in your table. In other words, your query should look something like this:

SELECT Val(paymaker_quanity) * Val(paymaker_unit_price) as Total
FROM paymaker
GROUP BY < This is where the "Region" expression would go, if only we had the information. >
WHERE userid = 123
            AND pmdate BETWEEN '20060101' AND '20060716'

Notice also how I made no mention of "Company" in the WHERE clause that is because you have not included it in your table structure or in any explanation as to how it is derived.
0
 
LVL 75

Expert Comment

by:Anthony Perkins
ID: 17117529
P.S.  In case you are wondering how you should post sample data, it is quite simple:
1.  Do something like this: Select TOP 20 * From paymaker
2. Copy and paste the output including the column names.
3. Given this output indicate what would be the desired output.
0
 

Author Comment

by:budgilbert67
ID: 17118156
Mabye if I explain how I created this form you will understand better.
I am using Dreamweaver MX
First I created a recorset querying my Access database
then I created a table on a ASP VBscript page with 6 columns and 5 rows.
ON the first row I named the columns Quanity: Discription: Taxable: (Yes/no) and Tatal:   The second I used the binding panel to place each coresponding recordset item with the title of the first row.   Then I selected the second column then selected"Repeat Region" from the server behavior panel in dreamweaver, and select "show all records". The third row is my sub total, the forth row is my tax and the last row is my Total.   Now, I have figured out how to get my total, my tax, and my grand total.  where I am having my problem is figuring out how to get the "repeating region to show the total for each record that it brings to the region.   I have tried the following, but only get the value for the first record in every row.   So if my quanity for my first record is 1 and the unit price is 100, and ten records are displayed, 100 will appear in the total colum for every record.    I hope that you now understand what I mean by repeat region.   Below is the query that I am working with.  Thank you.
SELECT Val(paymaker_quanity) * Val(paymaker_unit_price) as Total
FROM paymaker
WHERE userid = 'varuserid' AND pmdate >= 'varpmdate1' AND pmdate <= 'varpmdate2' AND company = Val('varcompany')
ORDER BY paymaker_total

thank you for your help so far
0
 
LVL 75

Expert Comment

by:Anthony Perkins
ID: 17118168
I give up.

Good luck.
0
 

Author Comment

by:budgilbert67
ID: 17118264
Here is the intire page with two records as you requested.  This is my page the way I have it working now.  I hope this will help you now.



<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
                                                      
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Paymaker.net Invoice</title>
<style type="text/css">
<!--
.boarders {
      border: thin none #999999;
}
.caps {
      font-family: "Times New Roman", Times, serif;
      font-size: 14px;
      text-transform: capitalize;
}
.optionheader {
      border-top-width: thin;
      border-right-width: thin;
      border-bottom-width: thin;
      border-left-width: thin;
      border-top-style: solid;
      border-right-style: none;
      border-bottom-style: solid;
      border-left-style: solid;
      border-top-color: #333333;
      border-right-color: #333333;
      border-bottom-color: #333333;
      border-left-color: #333333;
      font-family: Arial, Helvetica, sans-serif;
      font-size: 12px;
      font-weight: bold;
}
.optionheaderend {
      border-top-width: thin;
      border-right-width: thin;
      border-bottom-width: thin;
      border-left-width: thin;
      border-top-style: solid;
      border-right-style: solid;
      border-bottom-style: solid;
      border-left-style: solid;
      border-top-color: #333333;
      border-right-color: #333333;
      border-bottom-color: #333333;
      border-left-color: #333333;
      font-family: Arial, Helvetica, sans-serif;
      font-size: 12px;
      font-weight: bold;
}
.invoicerows {
      border-top-width: 0.87pt;
      border-right-width: 0.87pt;
      border-bottom-width: 0.87pt;
      border-left-width: 0.87pt;
      border-bottom-style: dashed;
      border-top-color: #000000;
      border-right-color: #000000;
      border-bottom-color: #000000;
      border-left-color: #000000;
      border-top-style: none;
      border-right-style: none;
      border-left-style: dashed;
}
.endrow {
      border-top-width: thin;
      border-right-width: thin;
      border-bottom-width: thin;
      border-left-width: thin;
      border-top-style: solid;
      border-top-color: #000000;
      border-right-style: none;
      border-bottom-style: none;
      border-left-style: none;
      font-family: Arial, Helvetica, sans-serif;
      font-size: 12px;
      font-style: italic;
      font-weight: bold;
}
.optionheaderendtotals {
      border-top-width: thin;
      border-right-width: thin;
      border-bottom-width: thin;
      border-left-width: thin;
      border-top-style: none;
      border-right-style: solid;
      border-bottom-style: solid;
      border-left-style: solid;
      border-top-color: #333333;
      border-right-color: #333333;
      border-bottom-color: #333333;
      border-left-color: #333333;
      font-family: Arial, Helvetica, sans-serif;
      font-size: 14px;
      font-weight: bold;
}
.style4 {font-family: Arial, Helvetica, sans-serif; font-size: 12px; font-weight: bold; font-style: italic; }
.nobackgroundrepeat {
      background-repeat: no-repeat;
      text-transform: uppercase;
}
.billtoshipto {
      font-family: Arial, Helvetica, sans-serif;
      font-size: 14px;
      font-style: italic;
      font-weight: bold;
      width: 50%;
}
table {
}
.fixedtablesize {
      table-layout: auto;
      width: 30px;
}
.style9 {
      font-family: Arial, Helvetica, sans-serif;
      font-weight: bold;
      font-style: italic;
      font-size: 12px;
}
.style12 {
      color: #666666;
      font-size: 24px;
      font-weight: bold;
      font-family: Arial, Helvetica, sans-serif;
      font-style: italic;
      text-shadow: 5;
}
.frameforpage {
      border: thin double #000000;
}
.logobackground {
      background-repeat: no-repeat;
      background-position: center  center;
      position: absolute;
}
.invoicerowsend {
      border-top-width: 0.87pt;
      border-right-width: 0.87pt;
      border-bottom-width: 0.87pt;
      border-left-width: 0.87pt;
      border-bottom-style: dashed;
      border-top-color: #000000;
      border-right-color: #000000;
      border-bottom-color: #000000;
      border-left-color: #000000;
      border-top-style: none;
      border-right-style: dashed;
      border-left-style: dashed;
}
body {
      background-image: url();
}
.style16 {font-size: 12px}
.style17 {border-top-width: 0.87pt; border-right-width: 0.87pt; border-bottom-width: 0.87pt; border-left-width: 0.87pt; border-bottom-style: dashed; border-top-color: #000000; border-right-color: #000000; border-bottom-color: #000000; border-left-color: #000000; border-top-style: none; border-right-style: none; border-left-style: dashed; font-size: 12px; }
.style18 {border-top-width: 0.87pt; border-right-width: 0.87pt; border-bottom-width: 0.87pt; border-left-width: 0.87pt; border-bottom-style: dashed; border-top-color: #000000; border-right-color: #000000; border-bottom-color: #000000; border-left-color: #000000; border-top-style: none; border-right-style: dashed; border-left-style: dashed; font-size: 12px; }
.style20 {border-top-width: 0.87pt; border-right-width: 0.87pt; border-bottom-width: 0.87pt; border-left-width: 0.87pt; border-bottom-style: dashed; border-top-color: #000000; border-right-color: #000000; border-bottom-color: #000000; border-left-color: #000000; border-top-style: none; border-right-style: none; border-left-style: dashed; font-size: 10px; }
-->
</style>
</head>

<body>

  <table width="85%" height="95%" border="0" align="center" cellpadding="0" cellspacing="0">
    <tr>
    <tr>
      <td width="95%" height="95%"><div align="center"><br />
        <span class="style12">
         
            &nbsp;
           
          </span><br />
      </div>
       
              <table width="604" border="0" align="center" cellpadding="0" cellspacing="0">
                <tr>
                  <td width="48" height="48" background="../img-invoice/banner-logo/logo-elegant-purple.jpg" class="nobackgroundrepeat">&nbsp;</td>
                  <td width="556" height="48" class="nobackgroundrepeat"><table width="100%" border="0" cellspacing="0" cellpadding="0">
                      <tr>
                        <td height="48" background="../img-invoice/banner-background/banner-brown.jpg" class="nobackgroundrepeat">&nbsp;&nbsp;&nbsp; <span class="style12">PETE BROWN CONSTRUCTION</span></td>
                      </tr>
                  </table></td>
                </tr>
                <tr>
                  <td></td>
                  <td></td>
                </tr>
              </table>
             
          <table width="617" border="0" align="center" cellpadding="0" id="customer info">
            <tr>
              <td width="305" rowspan="2"><table width="86%" border="0" cellpadding="0">
                  <tr>
                    <td><span class="style9">Bill To: </span></td>
                      <td>&nbsp;</td>
                  </tr>
                  <tr>
                    <td width="32%"><span class="style9">Company:</span></td>
                      <td width="68%">Harvy Retailer</td>
                  </tr>
                  <tr>
                    <td><span class="style9">Address:</span></td>
                      <td>855 Artic Circle</td>
                  </tr>
                  <tr>
                    <td><span class="style9">City, State, Zip: </span></td>
                      <td>Price, UT, 84501</td>
                  </tr>
                  <tr>
                    <td><span class="style9">Phone:</span></td>
                      <td>555-555-8888</td>
                  </tr>
                  <tr>
                    <td><span class="style9">Fax:</span></td>
                      <td>555-555-7777</td>
                  </tr>
              </table></td>
                  <td width="306"><table width="82%" border="0" align="left" cellpadding="0">
                      <tr>
                        <td width="42%" class="style9">Invoice #: </td>
                        <td width="58%">1000</td>
                      </tr>
                      <tr>
                        <td class="style9">Invoice Date: </td>
                        <td>7/16/2006</td>
                      </tr>
                      <tr>
                        <td class="style9">Customer ID: </td>
                        <td></td>
                    </tr>
              </table></td>
            </tr>
                 
            <tr>
              <td>&nbsp;</td>
            </tr>
            <tr>
              <td>&nbsp;</td>
                  <td>&nbsp;</td>
            </tr>
          </table>
         
          <table width="617" border="0" align="center" cellpadding="0">
            <tr>
              <td width="600" align="center" valign="top">
                  <table width="100%" border="0" align="center" cellpadding="0" cellspacing="0" id="field3">
                    <tr>
                      <td width="10%" class="optionheader">Quantitiy:</td>
                      <td width="9%" class="optionheader">Item:</td>
                      <td width="32%" class="optionheader">Discription:</td>
                      <td width="11%" class="optionheader">Taxable:</td>
                      <td width="19%" class="optionheader">Unit Price: </td>
                      <td width="11%" class="optionheaderend">Total:</td>
                    </tr>
                   
                      <tr>
                        <td class="invoicerows style16">5</td>
                        <td class="invoicerows style16">rrr</td>
                        <td class="invoicerows style16">test</td>
                        <td class="invoicerows style16">Yes</td>
                        <td class="invoicerows style16">$50.00</td>
                        <td class="invoicerowsend style16">$250.00</td>
                      </tr>
                     
                      <tr>
                        <td class="invoicerows style16">4</td>
                        <td class="invoicerows style16">rrr</td>
                        <td class="invoicerows style16">test</td>
                        <td class="invoicerows style16">Yes</td>
                        <td class="invoicerows style16">$40.00</td>
                        <td class="invoicerowsend style16">$250.00</td>
                      </tr>
                     
                    <tr>
                      <td class="endrow">&nbsp;</td>
                      <td class="endrow">&nbsp;</td>
                      <td class="endrow">&nbsp;</td>
                      <td class="endrow">&nbsp;</td>
                      <td class="endrow"><div align="right">Sub Total:</div></td>
                      <td class="optionheaderend">$410.00</td>
                    </tr>
                    <tr>
                      <td>&nbsp;</td>
                      <td>&nbsp;</td>
                      <td>&nbsp;</td>
                      <td>&nbsp;</td>
                      <td><div align="right" class="style4">Tax:</div></td>
                      <td class="optionheaderend">$28.29</td>
                    </tr>
                    <tr>
                      <td>&nbsp;</td>
                      <td>&nbsp;</td>
                      <td>&nbsp;</td>
                      <td>&nbsp;</td>
                      <td><div align="right" class="style4">Total:</div></td>
                      <td class="optionheaderend">$438.29</td>
                    </tr>
                  </table>
                 
                <p>&nbsp;</p>
                <table width="100%" border="0" cellspacing="0" cellpadding="0">
                  <tr>
                    <td><div align="left">Pete Brown Construction</div></td>
                    <td>&nbsp;</td>
                    <td>&nbsp;</td>
                    <td>&nbsp;</td>
                    <td>&nbsp;</td>
                  </tr>
                  <tr>
                    <td><div align="left">4567 Mytown Circle</div></td>
                    <td>&nbsp;</td>
                    <td>&nbsp;</td>
                    <td>&nbsp;</td>
                    <td>&nbsp;</td>
                  </tr>
                  <tr>
                    <td><div align="left">Vero Beach, FL, 32966</div></td>
                    <td>&nbsp;</td>
                    <td>&nbsp;</td>
                    <td>&nbsp;</td>
                    <td>&nbsp;</td>
                  </tr>
                  <tr>
                    <td><div align="left">5555555555&nbsp;&nbsp; Fax: </div></td>
                    <td>&nbsp;</td>
                    <td>&nbsp;</td>
                    <td>&nbsp;</td>
                    <td>&nbsp;</td>
                  </tr>
                  <tr>
                    <td><div align="left">Email: pete@brownconstruction.com</div></td>
                    <td>&nbsp;</td>
                    <td>&nbsp;</td>
                    <td>&nbsp;</td>
                    <td>&nbsp;</td>
                  </tr>
                </table>                <p>&nbsp;</p></td>
            </tr>
          </table>
          </td>
    </tr>
  </table>
 
</td>
  </tr>
</table>
</body>
</html>
0
 
LVL 75

Accepted Solution

by:
Anthony Perkins earned 500 total points
ID: 17118326
>>Here is the intire page with two records as you requested. <<
Sorry no that is not what I asked for.  I suggest you crack open MS Access and learn to use it to output the result from a simple query.
0
 

Author Comment

by:budgilbert67
ID: 17118796
acperkins, I know that you have really been trying to help me, and I appreciate everything.   However with a little trial and error I just figured this on out on my own.   However because of your continued willingness to help me solve this I will give you the points anyway.  Here is the query that solved this problem.

SELECT *,(paymaker_quanity * paymaker_unit_price) as total
FROM paymaker
WHERE userid = val('varuserid') AND pmdate >= 'varpmdate1' AND pmdate <= 'varpmdate2' AND job_condition = 'post' AND company = Val('varcompany')
ORDER BY pmdate DESC

Really seems so simple ofter all of this.  Thank you for your help
0

Featured Post

Free Trending Threat Insights Every Day

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

Join & Write a Comment

Entering time in Microsoft Access can be difficult. An input mask often bothers users more than helping them and won't catch all typing errors. This article shows how to create a textbox for 24-hour time input with full validation politely catching …
CCModeler offers a way to enter basic information like entities, attributes and relationships and export them as yEd or erviz diagram. It also can import existing Access or SQL Server tables with relationships.
Video by: Steve
Using examples as well as descriptions, step through each of the common simple join types, explaining differences in syntax, differences in expected outputs and showing how the queries run along with the actual outputs based upon a simple set of dem…
Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…

743 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

10 Experts available now in Live!

Get 1:1 Help Now