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

Accessing SQL database table via MS Access

Status
Not open for further replies.

debbiepy

MIS
Jan 19, 2005
43
US
I am havig issues with Access and SQL. I am trying to create a form to enter data into a SQL table. When I enter teh new record and move then enter the 2nd record, it changes teh 1st record to the 2nd record. And, if I enter another record it changes record 1 & 2 to the same as record 3. It is basically treating all records as ONE record. What am I doing wrong?

In addition when I view our payments sql table in the same database via access, it shows all the records with the same description name field but the other fields might be correct. Something strange is happening.

 
What do you mean by "and move then enter the 2nd record"? What is "move" in Access?

Is this a linked table from SQL Server? Is there a primary key? Are you seeing a "blank" form when you begin entering your second record?

Duane MS Access MVP
[green]Ask a great question, get a great answer.[/green] [red]Ask a vague question, get a vague answer.[/red]
[green]Find out how to get great answers faq219-2884.[/green]
 
Sorry, by move, I simply mean hit Enter to enter the 2nd record. Yes, the table is linked from SQL server. In addition, I have a combo box on the form to use as a lookup for one of the fields in the data entry table.

Info: Data Entry table: CampaignDailySales (camp_code, Sales_Date, Sales_Qty) This is the data entry table. Combination of camp_code and Sales_date is the primary key for this table. Camp_code is the link to the Campaign Details table where camp_code is the primary. I want the manager to be able to look up the camp_code in the CampaignDetails table and enter that code in the CampaignDailySales table.

I usually use MS Access Lookup function but do not know how to do that with a linked SQL table. Maybe this combo box is my issue.

Yes, I do see a blank form when I begin entering my 2nd record and after entering to go to the 3rd record, it changes all previous records above it to the 3rd records data.
 
Confirm these assumptions:
Your form's record source is CampaignDailySales and it is Continuous View.
You have three controls
combo box
control source: Camp_Code
Row Source: SELECT Camp_Code from CampaignDetails
Bound Column:1
Text box
Control Source: Sales_Date
Text box
Control Source: Sales_Qty


Duane MS Access MVP
[green]Ask a great question, get a great answer.[/green] [red]Ask a vague question, get a vague answer.[/red]
[green]Find out how to get great answers faq219-2884.[/green]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top