Access Code Help

R

Russ

I created a simple database that will be used to track company purchases. I
created three tables (main, list of departments, list of vendors). I created
a query that is based on the main table. From there, I created a form, which
is based on my query, that uses info from the dept and vendor table and
records everything in the main table.

Now, The first field in my Form is PO#. This is a "text" field and the
default value is INDS. I have another field called ID, which is not visible
on the form. This is an Auto number field.

I want to combine the PO field with the ID field so the PO# field reads
INDS1, next record will be INDS2 and so forth. Below is the code. What is
the modified code that I can use to make this work?

Thank you.

SELECT [Purchase Order].[PO#], [Purchase Order].ID, [Purchase
Order].Department, [Purchase Order].Vendor, [Purchase Order].Description,
[Purchase Order].Quantity, [Purchase Order].Cost, [Purchase Order].Shipping,
[Purchase Order].Tax, [Purchase Order].Cost*[Quantity]+[Tax]+[Shipping] AS
[Total Cost]
FROM [Purchase Order];
 
R

Robert M. Franz (RMF)

Hi Russ
I created a simple database that will be used to track company purchases. [..]
SELECT [Purchase Order].[PO#], [Purchase Order].ID, [Purchase
Order].Department, [Purchase Order].Vendor, [Purchase Order].Description,
[Purchase Order].Quantity, [Purchase Order].Cost, [Purchase Order].Shipping,
[Purchase Order].Tax, [Purchase Order].Cost*[Quantity]+[Tax]+[Shipping] AS
[Total Cost]
FROM [Purchase Order];

A query in one of the access-related newsgroups might result in better
results ...

Greetinx
Robert
 
C

Cindy M -WordMVP-

Hi Russ,

I think you selected the wrong group to which to post this... You're asking in
WORD.DocManagement - so your chances of getting a "useful" response aren't too
high :) An Access group would be better.

Right off-hand, I'd say you'd need something like:

SELECT [Purchase Order].[PO#]&[Purchase Order].ID AS PO_FullName, [Purchase
Order].ID, [Purchase
Order].Department, [Purchase Order].Vendor, [Purchase Order].Description,
[Purchase Order].Quantity, [Purchase Order].Cost, [Purchase Order].Shipping,
[Purchase Order].Tax, [Purchase Order].Cost*[Quantity]+[Tax]+[Shipping] AS
[Total Cost]
FROM [Purchase Order];

I created a simple database that will be used to track company purchases. I
created three tables (main, list of departments, list of vendors). I created
a query that is based on the main table. From there, I created a form, which
is based on my query, that uses info from the dept and vendor table and
records everything in the main table.

Now, The first field in my Form is PO#. This is a "text" field and the
default value is INDS. I have another field called ID, which is not visible
on the form. This is an Auto number field.

I want to combine the PO field with the ID field so the PO# field reads
INDS1, next record will be INDS2 and so forth. Below is the code. What is
the modified code that I can use to make this work?

Cindy Meister
INTER-Solutions, Switzerland
http://homepage.swissonline.ch/cindymeister (last update Jun 17 2005)
http://www.word.mvps.org

This reply is posted in the Newsgroup; please post any follow question or reply
in the newsgroup and not by e-mail :)
 
R

Russ

Thank you. I will post in proper group. Thanks again.

Cindy M -WordMVP- said:
Hi Russ,

I think you selected the wrong group to which to post this... You're
asking in
WORD.DocManagement - so your chances of getting a "useful" response aren't
too
high :) An Access group would be better.

Right off-hand, I'd say you'd need something like:

SELECT [Purchase Order].[PO#]&[Purchase Order].ID AS PO_FullName,
[Purchase
Order].ID, [Purchase
Order].Department, [Purchase Order].Vendor, [Purchase Order].Description,
[Purchase Order].Quantity, [Purchase Order].Cost, [Purchase
Order].Shipping,
[Purchase Order].Tax, [Purchase Order].Cost*[Quantity]+[Tax]+[Shipping] AS
[Total Cost]
FROM [Purchase Order];

I created a simple database that will be used to track company purchases.
I
created three tables (main, list of departments, list of vendors). I
created
a query that is based on the main table. From there, I created a form,
which
is based on my query, that uses info from the dept and vendor table and
records everything in the main table.

Now, The first field in my Form is PO#. This is a "text" field and the
default value is INDS. I have another field called ID, which is not
visible
on the form. This is an Auto number field.

I want to combine the PO field with the ID field so the PO# field reads
INDS1, next record will be INDS2 and so forth. Below is the code. What is
the modified code that I can use to make this work?

Cindy Meister
INTER-Solutions, Switzerland
http://homepage.swissonline.ch/cindymeister (last update Jun 17 2005)


This reply is posted in the Newsgroup; please post any follow question or
reply
in the newsgroup and not by e-mail :)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top