Field name changed automatically!!!

johnyjassi

Registered User.
Local time
Today, 00:52
Joined
Jun 6, 2008
Messages
64
Hi Guys,

Need help in this. I was trying to run update query. Table names are "Table A" and "Table B" and columns name, size, datatype is same. when I tried to populate Table B with values in Table A. when i run the query it changes the name of few fields (unknown to table.... and asking for manual input.....like, Exp1:[Table A].fieldname) I checked the table that fieldname exist there.
Your help will be appreciated. Thanks in advance.
 
Hi Guys,

Need help in this. I was trying to run update query. Table names are "Table A" and "Table B" and columns name, size, datatype is same. when I tried to populate Table B with values in Table A. when i run the query it changes the name of few fields (unknown to table.... and asking for manual input.....like, Exp1:[Table A].fieldname) I checked the table that fieldname exist there.
Your help will be appreciated. Thanks in advance.

It would help a lot to see three things:
  1. The structure of [Table A] (no data required)
  2. The structure of [Table B] (no data required)
  3. The exact text of the query in question.
Note: Using Table names that contain special characters such as spaces is not a good idea in the long run, and the names chould be changed whenever possible. Also, if any Field name is a reserved word (such as Date, Group, Length, etc.), you will also probably want to consider changing these as well.
 
here is the what you need....
thanks for your reply
 

Attachments

here is the what you need....
thanks for your reply


I see that you have two tables named [Master – Item], and [Master – Item2], and that your Update Query is as follows:
Code:
UPDATE [B][COLOR=#0000ff][Master - Item][/COLOR][/B] INNER JOIN [Master - Item2] 
    ON [B][COLOR=#0000ff][Master - Item][/COLOR][/B].Item = [Master - Item2].Item 
    SET 
        [B][COLOR=#ff0000][Master-Item][/COLOR][/B].Description = [master - item2]!Description,
        [B][COLOR=#0000ff][Master - Item][/COLOR][/B].[Pkg Qty] = [Master - Item2]![Pkg Qty],
        [B][COLOR=#ff0000][Master-Item][/COLOR][/B].Warehouse = [Master - Item2]!Warehouse,
        [B][COLOR=#0000ff][Master - Item][/COLOR][/B].[First Order Date] = [Master - Item2]![First Order Date],
        [Master-Item].package = [Master - Item2]!package;
You have Special Characters (in this case Spaces) in your Table and Column Names, and as a result, [Master-Item] does not represent the same Table as [Master - Item]. You will need to correct this. What you really should do is eliminate Spaces (and any other Special Characters from your Table and Column Names, making these kind of issues no longer possible. Don't worry, I am sure that you will find lots more new issues to take their place...
 

Users who are viewing this thread

Back
Top Bottom