Solved

doubt in query

Posted on 2008-10-09
4
200 Views
Last Modified: 2012-05-05
what is wrong with the query

UPDATE inbound_to_future (PartnerName,ManufacturerName,MPN,Region,ATS,SOQ) VALUES ("Future Electronics","AAEON ELECTRONICS             ","1702031802                    ","FUTC",0,1);
0
Comment
Question by:priyapratheep
  • 2
4 Comments
 
LVL 14

Expert Comment

by:Binuth
Comment Utility
insert into inbound_to_future (PartnerName,ManufacturerName,MPN,Region,ATS,SOQ) VALUES ('Future Electronics','AAEON ELECTRONICS','1702031802','FUTC',0,1)

0
 
LVL 14

Accepted Solution

by:
Binuth earned 500 total points
Comment Utility
update syntax


Update inbound_to_future
set PartnerName ='Future Electronics'
      ,ManufacturerName = 'AAEON ELECTRONICS'
      ,MPN = '1702031802'
      ,Region = 'FUTC'
      ,ATS = 0
      ,SOQ =1
Where
      <set your contition here>
0
 
LVL 6

Expert Comment

by:carlsiy
Comment Utility
Exactly what are you trying to do.. an insert query or an update query?
0
 
LVL 10

Expert Comment

by:GeoffSutton
Comment Utility
With SQL you cannot use full quotes ("), only single quotes (') as text identifiers.  Full quotes are treated as column names.

Also to update something you need a condition, otherswise every row in the table will get the same data.

Finally, you are using UPDATE while you have INSERT syntax.

For inserts use:
INSERT tableName (Column1, column2, column3) VALUES (value1, value2, value3)

For updates use:
UPDATE tableName SET column1=value1, column2=value2, column3=value3 WHERE (somecolumn=somevalue)

Hope this helps,

Geoff
0

Featured Post

Do You Know the 4 Main Threat Actor Types?

Do you know the main threat actor types? Most attackers fall into one of four categories, each with their own favored tactics, techniques, and procedures.

Join & Write a Comment

As they say in love and is true in SQL: you can sum some Data some of the time, but you can't always aggregate all Data all the time! Introduction: By the end of this Article it is my intention to bring the meaning and value of the above quote to…
This article describes how to use the timestamp of existing data in a database to allow Tableau to calculate the prior work day instead of relying on case statements or if statements to calculate the days of the week.
This demo shows you how to set up the containerized NetScaler CPX with NetScaler Management and Analytics System in a non-routable Mesos/Marathon environment for use with Micro-Services applications.
When you create an app prototype with Adobe XD, you can insert system screens -- sharing or Control Center, for example -- with just a few clicks. This video shows you how. You can take the full course on Experts Exchange at http://bit.ly/XDcourse.

772 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

9 Experts available now in Live!

Get 1:1 Help Now