Advertisement

05.01.2008 at 11:37AM PDT, ID: 23369590
[x]
Attachment Details
[x]
The Solution Rating System

With so many solutions, how can you tell which solutions are most likely to help you and which ones are not? To provide you with a tool to use, we rate our solutions based on various elements that most accurately determine if a solution is a quality solution. To explain what factors affect the solution rating, here are the elements we take into consideration when formulating our solution rating.

  • The Grade of the Solution
  • The Zone Rank of the Expert Providing the Solution
  • The Number of Author and Expert Comments
  • The Number of Experts Contributing
  • The Feedback of the Community

Your Input Matters
Because of the way the system is set up, the most important variable in this equation is you. As a member of Experts Exchange, you are able to cast your vote on the quality of the solutions in regard to how complete, accurate, helpful and easy to understand each solution is. When you provide your feedback, each rating is adjusted accordingly. So, if you see a solution that has a poor rating that you think is a good solution, let us know by rating it. As you do, the rating will be adjusted and will become more accurate for other members of our site.

If you have any suggestions that you would like to make for our rating system, please ask a question in the Suggestions Zone of Community Support.

Thank you!

8.8

Best method to batch update tables in sql server 2005

Asked by nuvium in SQL Server 2005, MS SQL Server, .NET

Tags:

Hi guys, here is my question. I am a developer, with a standing knowledge of SQL Server, but I am far from a DBA. Recently a client of mine asked me to write some scripts to allow them to batch update some of their product tables in a SQL Server 2005 database environment. Here's how they want it to work (simplified for the example):

Lets say that have a table filled with product information, we'll call it tblProducts. This table has 10 columns, with an identity column, ProductID, a model number, ModelNumber, a bunch of other data, then finally a Price. Originally, they wanted me to write code that would allow them to view into the database, change some stuff around, save their changes, all via the web (sort of like a content management system). Recently, they changed their minds, and want a download/upload approach to the updating.

What I mean by this is, they want to be able to generate an excel or comma delimited output from tblProducts, listing all the products contained within. The two columns they are most concerned with are the ModelNumber and the Price. Basically, this is to batch change price for a bunch of products via a spreadsheet or comma delimited list. They would go in manually and change the prices to their liking. Finally, they want to FTP up the document (or if there is a way to automate it in .net, that would work too), and batch update the table based on this new spreadsheet or comma delimited list. I would assume this would require writing some sort of DTS package that runs the file.

So my question, in parts, is this :
1) How can I write something that generates an outputted list of all the products in the database, in either excel or comma delimited, that they can download and modify.
2) Once modified, whats the best method to have them upload it to the webserver, or ftp it, and then update the table via this new file (I am a beginner at DTS, so excuse my greenness)

I hear about companies doing this sort of thing all the time, ive just never done it myself. Any help is appreciated. The site that this is all attached to is in ASP.NET/VB.NET, but I think the majority of the grunt work would be on the SQL side.

Thanks!!Start Free Trial
[+][-]05.01.2008 at 11:42AM PDT, ID: 21481354

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]05.01.2008 at 11:46AM PDT, ID: 21481395

View this solution now by starting your 7-day free trial. Setting up your free trial is quick, easy, and secure. We will return you to this solution, unlocked, when you're done.

 

About this solution

Zones: SQL Server 2005, MS SQL Server, .NET
Tags: SQL Server 2005
Sign Up Now!
Solution Provided By: angelIII
Participating Experts: 2
Solution Grade: A
 
 
[+][-]05.01.2008 at 11:48AM PDT, ID: 21481417

Assisted solutions are selected by the member who asked the question as a comment that contributed to their question's solution.

Start your 7-day free trial to view this Assisted Solution or ask the Experts your question.

 
[+][-]05.01.2008 at 11:55AM PDT, ID: 21481478

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 7-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]05.01.2008 at 11:56AM PDT, ID: 21481490

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]05.01.2008 at 12:04PM PDT, ID: 21481553

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]09.16.2008 at 11:29AM PDT, ID: 22491635

Experts Exchange has a courteous staff of administrators who help members get the most out of the website by means of administrative comments like this one.

Start your 7-day free trial to view this Administrative Comment or ask the Experts your question.

 
[+][-]09.16.2008 at 11:32AM PDT, ID: 22491669

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]09.20.2008 at 04:19PM PDT, ID: 22532181

Experts Exchange has a courteous staff of administrators who help members get the most out of the website by means of administrative comments like this one.

Start your 7-day free trial to view this Administrative Comment or ask the Experts your question.

 
 
Loading Advertisement...
20080716-EE-VQP-32 / EE_QW_2_20070628