Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

Column is specified more than once in the “SET” clause

Posted on 2013-10-24
9
Medium Priority
?
2,793 Views
Last Modified: 2013-10-28
Hello:

Attached is an Excel workbook containing tabs of data that I need to import into SQL tables.  There is an import tool that we use, for such activity.

In particular, I'm having an issue with the tab called "EmployeeTrainingCourses".  When I conduct the import of this data directly into a SQL table, I get the error message saying that the "Column [whatever] is specified more than once in the 'SET' clause".

I read online that this is a fairly common error message.  But, I don't see anything online addressing this error in terms of importing data.

The data is just what it looks like in the spreadsheet.  I simply want to import each row as a record in the table.  It should be pretty straightforward.  So, I don't know why I'm getting this message.

Any help is appreciated.

Thanks!

TBSupport
CertsLicTrain-EHW-Employee-Templ.xlsx
0
Comment
Question by:TBSupport
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 4
  • 3
  • 2
9 Comments
 
LVL 19

Expert Comment

by:Bhavesh Shah
ID: 39596953
hi,

can you share your query with us.
between for your reference, you can check out the link.

http://exacthelp.blogspot.in/2012/04/column-name-is-specified-more-than-once.html
0
 
LVL 1

Author Comment

by:TBSupport
ID: 39596956
Hi Brichsoft:

It's select * from [spreadsheetname$]  

The import tool has a UI that allows us to map fields from the select statement into fields in the table that we're trying to import into.

TBSupport
0
 
LVL 19

Expert Comment

by:Bhavesh Shah
ID: 39596973
is there any trigger?
0
Comprehensive Backup Solutions for Microsoft

Acronis protects the complete Microsoft technology stack: Windows Server, Windows PC, laptop and Surface data; Microsoft business applications; Microsoft Hyper-V; Azure VMs; Microsoft Windows Server 2016; Microsoft Exchange 2016 and SQL Server 2016.

 
LVL 1

Author Comment

by:TBSupport
ID: 39596999
No.  Good question.

TB Support
0
 
LVL 5

Expert Comment

by:MohitPandit
ID: 39597076
Hello,

I just tried to import same worksheet with help of "SQL Server Import & Export Wizard" and it did not give any error. Please find attached .png file here.

BTW, which import tool is using?

Best Regards,
Mohit Pandit
Snap-01.PNG
0
 
LVL 1

Author Comment

by:TBSupport
ID: 39597127
SmartConnect.

It might be a moot point, though.  I had to get this done, ASAP, and was able to get this data imported through Microsoft Dynamics GP's Table Import tool.

I am curious, though, as to why this error comes about in SmartConnect.  Their tech support never got back to me, and I had to move forward.

TBSupport
0
 
LVL 19

Expert Comment

by:Bhavesh Shah
ID: 39597168
hi,

problem is

either one column is inserted twice, either virtually or
or
there could be some trigger, which may affecting.

if you can share us whole error message, it help us to give reply
0
 
LVL 1

Author Comment

by:TBSupport
ID: 39598247
All of the columns get this error, but here is the one for the EmployeeID column:

The column name 'EmployeeID' is specified more than once in the SET clause. A column cannot be assigned more than one value in the same SET clause. Modify the SET clause to make sure that a column is updated only once.

TBSupport
0
 
LVL 5

Accepted Solution

by:
MohitPandit earned 2000 total points
ID: 39599660
Hello,

I don't have SmartConnect.

But these type of error comes either any insert triggers applied or UPDATE with same.
Please find below links
http://social.msdn.microsoft.com/Forums/en-US/7ba617ee-eb46-4ecc-9a3b-22d1dfc5a3c3/error-msg-264-regarding-set-clause

http://exacthelp.blogspot.in/2012/04/column-name-is-specified-more-than-once.html


Best Regards
0

Featured Post

Comprehensive Backup Solutions for Microsoft

Acronis protects the complete Microsoft technology stack: Windows Server, Windows PC, laptop and Surface data; Microsoft business applications; Microsoft Hyper-V; Azure VMs; Microsoft Windows Server 2016; Microsoft Exchange 2016 and SQL Server 2016.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In this article I will describe the Backup & Restore method as one possible migration process and I will add the extra tasks needed for an upgrade when and where is applied so it will cover all.
In this article I will describe the Copy Database Wizard method as one possible migration process and I will add the extra tasks needed for an upgrade when and where is applied so it will cover all.
Monitoring a network: how to monitor network services and why? Michael Kulchisky, MCSE, MCSA, MCP, VTSP, VSP, CCSP outlines the philosophy behind service monitoring and why a handshake validation is critical in network monitoring. Software utilized …
Sometimes it takes a new vantage point, apart from our everyday security practices, to truly see our Active Directory (AD) vulnerabilities. We get used to implementing the same techniques and checking the same areas for a breach. This pattern can re…

722 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