Queries :: Text To Number Query

May 28, 2013

I have a linked table to Access 2010 which contains tracking numbers for shipments.When I link the spreadsheet to the Table, the FedEx tracking numbers are changed to for example - 9.813842152e+014 instead of 981384215196229. Is there anyway to change these back to its original format? I was thinking of creating a query where I could use Conversion Function, but it kept giving me error. Please note that both the UPS Tracking and FedEx tracking are in the same field.

View Replies


ADVERTISEMENT

Queries :: Update Query To Replace Number With Text

Apr 15, 2014

I've made a simple form to Login/Logout with radio buttons but the buttons only allow me to push a number as a value, in my case 1 or 2 for Login or Logout.

How would I make an update query to change those numbers to the equivalent text? Or is that not possible in the same field because that is 2 different data types?

View 5 Replies View Related

Queries :: Changing A Text Field Into A Number Field Using A Query

Jul 31, 2014

I currently import data into a table and it it has a text field which looks like this: 12,345.67 GBP...I need to use a query to make this a number field so that I can sum it's contents. I've managed to remove the 'GBP' part but can't seem to get rid of the comma?

View 4 Replies View Related

Queries :: Place Number With Text Selection

Mar 12, 2014

I have a table with a field name compliance level which is filled with drop down list and having like this;

poor
good
excellent
IR

Now what I want is if i select poor from list then in query it generate -10 in query field named analysis, same if select good then generate 10 and so on means i will assign numbers for each field...

One can select only one item like, poor at one record entry...

View 4 Replies View Related

Queries :: Change Number In A Table To Display Text

Feb 27, 2014

I'm trying to change a 1,2,3 in a table to display NA, Yes, No on a form.

I have an Infopath form with a n/a,yes,no drop down that is dumped into Access. Infopath requires a value be tied to them so it is 1,2,3. So in Access, my table shows the numbers and not the text. I would like to know how to get my access forms to show the text instead. Not sure if I should be setting the field criteria in my query to say if this field is a 1 make it Yes, if 2 make it NO, if 3, make it NA. Or if there is something completely different to do.

I found a workaround by going into the query and using Find and Replace but I need this to update itself automatically.

View 3 Replies View Related

Queries :: Work Order Number - Criteria To Filter By Text?

Jun 30, 2015

Is it possible to do a criteria like the "Between" to pull data like a work order number?

Ex WO#: WO5551212

I would like to be prompted to enter a Work Order Number when I run a query, then have the query display all of the data for that particular work order number.

View 4 Replies View Related

Queries :: Convert Phone Number In Text Format And Remove Dashes Or Parenthesis

Aug 7, 2014

Is there a way to convert a phone number in text format into a number and remove any dashs or parenthesis. What function can I use ?

old format (951) 244-3011
new format 9512443011

View 2 Replies View Related

Format A Number As A Text In A Query

Apr 5, 2007

Hello,
I have a text file I'm querying that stores a field as a text.
ComponentID:0000000242

I'm inserting this data into a table that stores this value as a number. Thus truncating the leading zeros.
ComponentID:242

I would like to create a query on the table using an InnerJoin on the text file column:ComponentID:0000000242 and the table column:ComponentID:242 as the unique identifier. Doing this join gives a case error because of the different data types.

Can format ComponentID using a query so it reads from my table as 0000000242 and do an InnerJoin to the text file. In vb
String= Format(242, "0000000000")
But I'm finding it difficult to get the query to format this correctly.

Unfortunately, i'm unable to change the column data type in the table structure and am looking for a work around. Is this even possible? Any ideas?

Thanks.

View 1 Replies View Related

Convert Number To Text In Query

Dec 1, 2007

I want to have a question in my query that does not get answered by date but by a concatenated field named "MonthYearPeriod".

We always forget how many days in a month. But we remember the month and year. So for say a Sales Range of Nov 2006 to Oct 2007, we prefer to respond to the criteria question as: 11-2006 and then 10-2007.

FiscalMonth and FiscalYear are both Long Integer number fields in the table.

Query field concatenated:
MonthYearPeriod: [FiscalMonth] & "-" & [FiscalYear]

criteria line:
Between [Month-Year START DATE] And [Month-Year END DATE]

However, i get other crazy time periods. So this is not working. Maybe on the Query field box, I need extra coding to convert the number to text?

I assume that a Dash sign between the month and year are fine.
Thanks

View 5 Replies View Related

Use Form & Query To Search For Text & Number

May 19, 2006

Hello,

I have a form with a listbox on, the listbox uses a query to populate it, which returns a list of client names. The idea is, when I enter the clients name in a text box, the list is narrowed, through use of the query.

This works fine, and always has - very pleased with it, the problem comes when I decide I want to be able to search on the account number as well - which it always throws errors about.

I am using the following query (posting the sql, hope that is OK)

SELECT tblSafeKeep_Clients.SafeKeepClientID, tblSafeKeep_Clients.Title, tblSafeKeep_Clients.Initials, tblSafeKeep_Clients.Surname, Format(tblSafeKeep_Clients.DesignationNumber,"000000") AS Expr1
FROM tblSafeKeep_Clients
WHERE (((tblSafeKeep_Clients.Surname) Like "*" & [Forms]![frmSafeKeep_SelectClient]![txtSearchText] & "*")) OR (((tblSafeKeep_Clients.DesignationNumber)=[Forms]![frmSafeKeep_SelectClient]![txtSearchText]));


The problem is because I am only using ONE text box, but the surname is (obviously) text, and the account number is (obviously!) a number. SO - it throws a wobbler about it being too complex to evaluate when I try to search for a surname, trying to search for an account number works just fine.

Any ideas how to get around this?

View 3 Replies View Related

How To Convert Number Date To Text In Access Query

Feb 12, 2015

how to convert number date to text date.

Ex. Date field: 02/12/2015

convert into:

Month field
February

Day Field
12

Year
2015

View 3 Replies View Related

Number Fields In Text To Number Field, Formula For Fiscal Year

Nov 26, 2004

Date of Birth (DOB) field etc. in one program are text - how do I make another file with the same data into number fields for Date of Birth field etc? When I copy data to file that has number fields the 09252004 is changed to 9252004. Can I get reports with the correct Date of Birth in them by moving data from text file to number file?

There is data entered monthly in file and formula has been set up for January, February etc as ---quarter: Int(([month]-1)/3)+1. I would like formula for the fiscal year for April to be counted as month 1, May - month 2, June as month 3, July as month 4, August as month 5, Sept as month 6, October as month 7, Nov as month 8, Dec as month 9, Jan as month 10, Feb as month 11 and March as month 12.

Thank you

View 6 Replies View Related

Forms :: DLookup - Using Two Fields (number And Drop Down Text) To Query Table For Data

May 29, 2015

DLookup function. (this is for a stamp collection database).

On my form ("InventoryInput") I have a text box called "Catalog" for a numeric entry and a text combo box for selecting a "Country" in drop down list.

I want to query a table called "CatNameList" to get the "StampName" of the item (based on the entries of Catalog and Country) and populate that name in the text box. The fields in this table are called "StampName", "CatNumb" & "CName" respectively.

I have successfully placed the following expression in the control source of that textbox and able to populate the StampName I need based solely on the catalog number alone.

That express is :
=DLookUp("StampName", "CatNameList", "CatNumb = Form![Catalog]")

So it will populate the "StampName" data to match the "Catalog" number entry just fine.

However, I need to add a second layer to incorporate the Country.

Example : There is a catalog "1" for "USA", and a catalog "1" for "Canada" but both have different "StampName".

I have been attempting to get that second piece added with no success. Here is the expression I have been trying to get to work :

=DLookUp("StampName", "CatNameList", "[CatNumb] = " & [Catalog] & " And CName = '" & [Country] & "'")

Right now, the text box is just blank with the above expression. I thought it may be because there was no match found, but I have triple checked to ensure I have the spelling correct on the country name in both places.

Basically, I just need the dlookup to take the "catalog" and "country" off the form and match it to the "CatNameList" table fields of "CatNumb" and "CName" to give me "StampName" field back on the form.

View 4 Replies View Related

DLookup - Using Two Form Fields (Number And Drop Down Text) To Query Table For Data

May 29, 2015

Having problems getting dlookup to work in the control source field of a text box.

My form has fields : Catalog # (numeric value) and Country (drop down text selection).

I would like to query a table CatNameList for a name (text) if the catalog # and country find a match on the table.
My field names on the CatNameList table are : Name, Number (to validate against the Catalog # entered on the form) and CName (to validate against the Country drop down on the form).

I am successfully able to populate the name from the CatNameList table on my form using lookup of the catalog # using this :

=DLookUp("Name","CatNameList","Number = Form![Catalog #]")

However, I will eventually have several catalog numbers that will be identical in the table CatNameList, thus why the country is important as the second criteria to be added into the dlookup.

I have tried for a few hours unsuccessfully to add the second portion to my dlookup.

This is what I have currently (not working) that I have been playing with, I'm sure I'm missing a quote mark, & or something simple.

=DLookUp("Name", "CatNameList", "Number = Form![Catalog #] And CName = ‘”& Form![Country] & ”’”)

View 14 Replies View Related

Queries :: How To Insert A Prompt For Number In A Query To Calculate Against Another Field In Query

Jul 15, 2014

I have a field that is giving me the number of business days between a period of time and then I want to subtract that number - the person's PTO time to see the actual days they were available...when I simply type the number in (see below) it works great but I want to set up a prompt that will ask me how many PTO Days to calculate as it will be different for each person I am quering...is this possible?

View 9 Replies View Related

Queries :: Number Limiting Query

Jun 2, 2013

In table1 students lectures data are stored as:

Code:
ID studentname lecturesubject lecturedate
1 steve politics 3/2/2013
2 jack politics 3/2/2013
3 steve math 5/2/2013
4 steve politics 7/2/2013
5 jack politics 8/2/2013
6 steve math 8/2/2013
7 jack politics 9/2/2013
8 steve politics 10/2/2013
9 steve math 11/2/2013
10 steve physics 13/2/2013
11 jack politics 15/2/2013

We need a query in which for each student is allowed to preset a limited number of lectures on a specific subject. For example each student can provide only two lectures on a subject and any more lectures on the same subject presented by him will not be counted. In the above example records 7 8 9 and 11 will not be shown in the query.

View 3 Replies View Related

Queries :: Auto Number Field In Query?

Nov 22, 2014

I don't know why is it so complicated to add an auto number field in a query. I would like to add a increment number (auto number) on each line and then an auto number on each product.

View 7 Replies View Related

Queries :: Query To Count Number Of Different Records?

May 28, 2014

If I have a table called "Calls" with an autonumber and another field with names for stores like this:

1 Hobby Mart
2 Peter's Store
3 Hobby lobby
4 Hobby Mart
5 Peter's Store

How can I build a query to count the number of different store names?

For example, in this case I need the query to return the number 3.

View 7 Replies View Related

Queries :: Query To Add Sequential Number To Table

Dec 16, 2013

We have a large database table [PRODUCT] with the following fields PROPNUM and P_Date and GAS. We need to normalize the GAS field to the first month of production based on P_Date and sequential months following to average the data. We believe the easiest way is to create a sequential number for each Key PROPNUM that represents the first month of GAS the second month of GAS etc.

We have followed several of the posts on how to sequentially number records, but are struggling to get them to work.The latest effort was to use the make a table query creating an expression with the following.

DCount("*","PRODUCT","[PROPNUM]=" & [PROPNUM] & " AND[P_DATE]<=#" & Format([P_DATE],"mm/dd/yyyy") & "#")

View 2 Replies View Related

Queries :: Week Number Query When Year Changes

Feb 28, 2014

I analyse things by the date they are ordered by the office.

The date gets put into a spreadsheet and i import this into access for the querying.

I need to summarise it by weeknumber and year.

I use the following queries:

To get the week: Week Number: DatePart("ww",[DateOrdered],0,2)
To get the year: Year: Year([DateOrdered])
To put it together: Weekyear: [Year] & "_" & [Week Number]

The problem is when the year changes.

The dates for week 1 for 2014 are between 30/12/2013 and 05/01/2014 and therefore straddles 2013 and 2014.

Therefore when the year and week number is put together the following results are given for that particular week:

DateOrdered - Result of above query
30/12/2013 - 2013_1
31/12/2013 - 2013_1
01/01/2014 - 2014_1
02/01/2014 - 2014_1
03/01/2014 - 2014_1
04/01/2014 - 2014_1
05/01/2014 - 2014_1

All of the above should all read 2014_1 but some obviously are 2013_1. This causes me problems when doing further analysis and cross tabulations.

How can I amend my query so that the above all show the correct year and week number: 2014_1 ?

View 9 Replies View Related

Queries :: Finding Latest Number Using A Query

Jun 19, 2013

I need to find the latest number using a query.

All of the numbers follow this format:

[Doc No]
ABCD123

but the tricky part is the number could be suffixed with a revision. It is the latest revision I would like to find. For example, If I have a number followed by 3 revisions I would have:

[Doc No]
ABCD123
ABCD123+200
ABCD123+300
ABCD123+400

I need a query to give me the latest revision, in this case

[Doc No]
ABCD123+400

There is a possibility there are no revisions in which case the latest will be

[Doc No]
ABCD123.

How is this possible in a query???

View 5 Replies View Related

Queries :: Run Query Based On Number Of Fields

Mar 26, 2013

I have an excel data file that is updated monthly (and I am not able to have the source file format changed of course) that will be my linked table for Access 2007. The file reports monthly data and adds the new month to the right of the historic in a layout like this:

Tree | Orchard | Province | Jan % red | Jan % green | # Limbs | Feb % red | Feb % green... etc so each month it adds 3 new fields to the data.

I have queries (rightly or wrongly) that will calculate the number of apples that month and report on those higher than a certain percentage. I would like to do this without having to create a static table to append to each month as the new data file will always show the full YTD results anyway (and I don't like to store data in my database).

I have a query that counts the number of fields in the raw data file and am wondering if there is a way to have access only run the number of queries required based on the number of fields. i.e. if 11 fields then run queries 1 thru 5, if 14 run 1 thru 6 etc.

View 3 Replies View Related

Queries :: Query To Display Number Of Records Per Value

Aug 9, 2013

I have a date field in a table. I wish to display in a query:Column A representing the month. Column B representing the number of records in the table corresponding to that month.

View 5 Replies View Related

Queries :: Parameter Query To Search For Number

Feb 11, 2015

I have 2 tables: Table A contains [ID] (and other columns) AND Table B contains [Request ID] (and other columns).

However, [Request ID] contains several number separated by comma. For example: 10, 15, 20 etc.

I created a query with parameter with : Like "*" & [ID] & "*" under [Request ID] criteria.

Here is my problem:

if [Request ID] = 44, 60 then it is returning [ID] 4 records (4, 6, 44, & 60). Is there a way to show only 2 records? 44 & 60?

View 4 Replies View Related

Queries :: Value In Query Returning As String And Not A Number

Apr 3, 2014

I have a query which runs fine, however one of the outputs is a calculated field and i use the Format(someValue,"Fixed") method of specifying the format for the % Change .Here is the query

Code:

SELECT tblTempBearsWeek3.SymbolCode AS [Short Ticker], tblTempBullsWeek3.SymbolCode AS [Long Ticker], tblTempBearsWeek3.[Week 3 Date], tblTempBearsWeek3.Short, tblTempBullsWeek3.Long, tblTempBearsWeek3.[Short Week 3 Close], tblTempBullsWeek3.[Long Week 3 Close],

[code]...

The problem is that the % Change calculated field for some reason comes out as a String. i know this because when I try and sort on that column, it sorts it as if it is text and not a number value i.e. it doesn't put it in Ascending order.

View 2 Replies View Related

Queries :: Crosstab Query - Counting Number Of Records For Each FY

Sep 19, 2013

I have been tasked to create a DB for my unit. I have created a few DB, but I am a novice at best. I need a crosstab Query to count the number of records for each FY. The Army's FY is from Oct -Sep. I only need to show the the total number of record for the previous FY in a Report and on a form.

View 7 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved