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 Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Format field in a Union query 1

Status
Not open for further replies.

scottian

Programmer
Jul 3, 2003
955
GB
How do i format a field in a union query?
Ive looked old posts and found Cstr, but i cant get it to work.
In my table the field shows the number correctly. 4402540360011
But when i run the union query the number appears as
4.300134658011E+12

This is what i thought was the correct function, Cstr([CRN]) but i keep getting the error undefined function 'tblMyTable.cstr' in expression.

can anyone help?

"Children are smarter than any of us. Know how I know that? I don't know one child with a full time job and children."...Bill Hicks
 
Code:
SELECT
    Table1.fld1
  , Table1.fld2
  , CStr([fld3]) AS NewFormat
FROM
   Table1
UNION 
SELECT
    Table2.fld1
  , Table2.fld2
  , CStr([fld3]) AS NewFormat
FROM
   Table2;

________________________________________________________
Zameer Abdulla
Help to find Missing people
 
Thank you, your a diamond

"Children are smarter than any of us. Know how I know that? I don't know one child with a full time job and children."...Bill Hicks
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top