SSN query criteria

In my table all SSN data is showing in the format 000/00/0000CC;;_ (13 characters- example 000-00-0000AA).

I would like to create a query which returns only part of the SSN field, basically only the first 11 digits.

I have created a text box on a search form along with a cmdbutton that opens the form. The query has this criteria:

forms!mysearchform!txtSSN

Sponsored Links:

Related Topics

Multiple Criteria in DSum expression
I am currently programming a report that needs to spit out all of the money paid to a specific client. The Dsum function I used was:

=DSum("CashforVisit","Financials","Financials.SSN= " & [SSN])

Which worked excellent. However, I need a way to add another criteria to the DSum function, specifically that the payments happenned in 2011. This report grabs information from table Financials, which documents every payment, the SSN of the recipient, and the date of the payment.

Values to sum: CashforVisit
Table name: Financials
Criteria1:"Financials.SSN= " & [SSN]
Criteria2: DateofVisit >= 1/1/2011
Criteria3: DateofVisit


Error 3085 Function Mid not defined
I am just trying to upgrade my database from 2003 to Access 2007 (I have VISTA) and have notice that when I open a form I get an error message 3085, function mid not defined.
I assume to problem is caused by a list box on my form which has as a records source a query with a field:
LastTwoDigits: MID ([SSN], 12,2).
This criteria returns the last two digits on a SSN. This is quite strange because in Access 2003 I don't get any error message. If I remove the listbox then, the error message disappears. I have looked at the references and what is missing is the Microsoft Office Control 1.0 Type Library. I have removed it but still get the problem.
This is the SQL in my query:

SELECT mytable.BGN, mytable.[ssn], mytable.BLN, Mid([mytable],12,2) AS BIC, Left([ssn],11) AS SocSecNo, mytable.Amount FROM Mytable WHERE (((Left([ssn],11)) Like forms!welcome!ssnsearch)) ORDER BY mytable.BGN, Mid([ssn


SSN Format
I'm importing a ms excel spreadsheet into an access table. The spreadsheet contains a column with SSN's. I'm having a problem with access including recognizing SSN's that start with a "0". It will only show part of the SSN (the #'s that are not zero). The spreadsheet correctly identifies the whole SSN. I have setup the table field to an imput mask for SSN but still not working.


linking Querries
I am having problems like usual. Here is what I am trying to do

I have an imported table that has only SSN on employees. On another table I have employees SSN and first name and last name and all other kinds of info.

How would I run a querry that would use the SSN's that I got on the one table and display the correct name for the ssn


Query Duplicates- Access 2003
I have about 52k of records with duplicates.

It is a list of names with SSN. Where there are two names with the same SSN and name, one my have a middle initial and one without one, or any combination with the Initial. I would prefer the one that does have the Initial, but then also get one of the duplicates that does not have this criteria to consider for the next record comparison.


Query to find id's with duplicate data across multiple tables
I have 6 tables with the same design but the data is different because they are pulling data from 6 different places (it is an ODBC connection to other databases).

I want to create a report that will show me the id for each row.

The table design is: employeeID, SSN, Name .

So, I want a report that will show me every SSN and for each SSN, I want to see the employeeID (if it exists) for each table.

The columns for the report would be: SSN, employeeID1, employeeID2, employeeID3, employeeID4, employeeID5, employeeID6


Trying to Link tables
I am still new to access and need a little help to do something that is probally really simple.

I have a table that contains all the information that I need for my event. The data that is important for this question is the Last Name, First Name, Rank and SSN.

What I want to do is to be able to put the SSN into an access table via a barcode reader. This is not the problem. the problem is that after I input the SSN, I would like the Last Name and First Name and Rank to populate on the table that the SSN is scaned into.

Any help would be better than what I have know.


Field auto add numbers to value
I have a field for SSN. If the SSN has a 0 or 00 as the first numbers it auto deletes those numbers. Is there a way in access that when the record is visible the 0's are relpaced so that the SSN will read the 9 digit.

Also I have another fiels EIN with 7 digits an I need for there to be 2 9's in the beginning. I was goingto use vba but when I go to yp it I only get .value <

Me.SSN.Value

Value is tho only option to get. IDK y it does this or how to get it to shop if there is a ay.


Query Help: MS Access and FileMaker Pro
I am writing my first database app (windows form in c#) and I am using an access database. I have 2 tables with the following fields:
payroll: (Store, lastName, PayFreq, SSN (PK), HireDate, EffectiveDate, TermDate, DeductionCode, Deduction, NAD CHAR) AND hrconnection: (Store, lastName, CoTime, Plan, Dependants, HireDate, EffectiveDate, TermDate, SSN (PK), Deduction).
I want to find the records based on SSN that are in the payroll table and are not in the hrconnection tables and then find the record based on SSN that are in the hrconnection but are not in the paypal table.


Examples of query criteria
When you want to limit the results of a query based on the values in a field, you use query criteria. A query criterion is an expression that Access compares to query field values to determine whether to include the record that contains each value.
In this topic:
* Introduction to query criteria
* Criteria for Text, Memo, and Hyperlink fields
* Criteria for Number, Currency, and AutoNumber fields
* Criteria for Date/Time fields
* Criteria for other fields


Append Query to add column?
I am a self taught Access user, I know a little VBA but not much.

Here is my issue: I currently have a database populated with thousands of records and now all of a sudden the folks I work for want to add in another column of data. The primary key main table are SSN. I have an excel spreadsheet with this new column of data and the related SSN.

I do not want to have to data entry each of these values, so how can I get the data for this new column into the associated rows?

My first thought was an append query.but I just can't seem to get it to work. Any ideas on how best to get this done


Append Query to add column?
I am a self taught Access user, I know a little VBA but not much.

Here is my issue: I currently have a database populated with thousands of records and now of a sudden the folks I work for want to add in another column of data. The primary key main table are SSN.

I have an excel spreadsheet with this new column of data and the related SSN.

I do not want to have to data entry each of these values, so how can I get the data for this new column into the associated rows?


ALike syntax
I'm using a search form to search for records in my main database. In the following code, everything works fine with exception of the Alike statement for the SSN. I would like to search by only the last four of the SSN. I've tried several variations and several wildcards including "*","%","_","?","#" none of these work. The code below is the closest I've come but not quite there. If I enter four digits into the [SSN] field on the form it will pull up the SSNs that match. That part is fine. The problem is that when the [SSN] field is blank it will not find any records. (Yes I have the default value of the textbox set to "") I'm sure it's just a syntax problem but have no idea what it is?


Creating unique ID's
I have a database in Access 2010 that I've put together to help audit enrollment data. Using the SSN as a unique field for each employee, I was able to put together a system to audit the data for employees. However, I am getting stuck with auditing the dependent data.

The data we receive from vendors does not give a unique ID for each dependent. The dependent SSN is not a required field, so it is most often either missing, or it is filled in with a dummy SSN, such as 999-99-9999.

The basic structure of the database so far consists of three tables. Two tables house employee data and dependent data on our end (they are exported as separate files in our system) and thethird table is used to import the employee and dependent data from the vendor's side (they include employees and dependents on the same file).

To perform the actual audit, I have queries set up to pull out and format the employee data from our end and the vendor employee data. Then there is another query which compares those twosets of data together to find the differences, using the employee SSN as a unique key for each record.


Strip input mask in query results?
I have a client table with a social security number field that uses the MS Access Data Input Mask Wizard value for Social Security Number. I am automating an online application form for clients that requires the SSN without the mask (just straight 000000000). When I examine my query that is the source for the online form data, I can click on the properties tab for the SSN field in the query but there is no value corresponding to "Input Mask" so there is nothing to try and clear.


TextBox to Count Records in tables
I have a form based on Table1. This table gets updated periodically with data via text file. Records that need to be updated, get saved into two other different tables, Table2 and Table3. All three tables have the SSN field.

I open Table1 via a form. On this form I have placed two text boxes which I would like to count records in Table2 and Table3 that have the same SSN. I am using this code that works for one txtbox but cannot make work for the second textbox. I have tried to copy the same code just changing the field and table name but still nothing. Any Help" Thank you.

Dim MySSN, mySSNCount
MySSN = Me.[ssn]

mySSNCount = Nz(DCount("[ssn]", "[Table1]", "[ssn]='" & MySSN & "'"), 0)
Me.[txtCountTable1] = mySSNCount


Query to identify added dependents
I have two tables with identical fields, each giving the enrollment data for a given month. Each employee has several lines, e.g. one for medical, another for dental, and another for vision. Additionally there are lines for medical, dental, and vision for each dependent. Each employee may have a dozen or more lines to cover every policy for every dependent. Both tables have the following fields:

Group#, Insured SSN, Insured Last Name, Insured First Name, Mbr SSN, Mbr Last Name, Mbr First Name, Relationship, Birth Date, Sex, Coverage

To make matters a bit more complicated, Mbr SSN is not present for all records (in fact is missing for most). The two tables are named PMD and TMD (Previous Month's Data, This Month's Data).

What I'm trying to identify are any new enrollments, e.g. someone adding a spouse or domestic partner. I was able to design a query to pull any new employees...


Simple Nav Form Code Not Working
I have a form with an unbound text box called SSN. I want user to enter a Social Security Number there and click a button which runs the following:

DoCmd.OpenForm "frmDropStudents", , , "[SocialSecurity] = " & [SSN]

frmDropStudents is opening as "filtered" showing a blank record.

This doesn't work either (same result as above):
DoCmd.OpenForm "frmDropStudents", , , "[SocialSecurity] = " & Me.SSN


Custom Import from Excel to Access
My Excel spreadsheet's format is as follows:
Name | Group NO | SSN
Name 1 | 1 | SSN Number

and so on.

My Access table format is as follows (how I would like my information to appear on Access):
[code]

How can I import the information So that the group number from the excel sheet corresponds to the record number on the Access Table. Also, listing out the Name and their SSN to thecorresponding columns for each group number.


Create a Query in Microsoft Access Using Simple Equal To Criteria
This quick and easy tutorial will explain how to create a query using criteria. There are MANY types of criteria that can be used in a query, but for now we'll focus on a basic query to get started.
We will first see how to retrieve customer data for customers that live in a particular state. Then, we will see how to expand this criteria to search for customers across multiple states at one time.