Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8393441
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 9, 20262026-06-09T19:47:16+00:00 2026-06-09T19:47:16+00:00

I have some SQL skill but I have a problem: I currently get a

  • 0

I have some SQL skill but I have a problem:
I currently get a monthly excel sheet via email containing 1 sheet of information. I need to be able to completely update and replace a table in SQL server 2008 (express) with this information.

I have tried to create a proceedure to drop the table and recreate it using something like this

Drop Table Utah

Create table Utah


Insert into dbo.[Utah] 
Select *    FROM OPENROWSET('Microsoft.Jet.OLEDB.4.0', 
        'Excel 8.0;Database=c:< .sxl file here>;HDR=YES', 
    'SELECT * FROM [Utah]')

But im not having any luck when I try to make a proceedure for this.

Each step seems to work on its own but to streamline this and make it easy for others to do – Can you help me please?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-09T19:47:18+00:00Added an answer on June 9, 2026 at 7:47 pm

    The best way to handle this is to create SSIS job.

    There you can automate the process to handle excel files and refresh the sql tables and all.Its going to be very smooth and handy.

    In case of SQL Express tyr to run this code as Sproc

    IF EXISTS(select * from sysobjects where name='Utah' and type='U')
    DROP TABLE Utah
    GO
    
    Create table Utah(col1 int,col2 int)
    Go
    
    Insert into dbo.[Utah] 
    Select * FROM OPENROWSET('Microsoft.Jet.OLEDB.4.0', 
            'Excel 8.0;Database=c:< .sxl file here>;HDR=YES', 
        'SELECT * FROM [Utah]')
    
    Go
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm getting crazy with this problem: I have got some Oracle SQL-Reports to redesign
In my .net application, I have used LINQ-to-SQL to get some data from the
I have some sql statements that calculates some numbers. It's possible (with bonus points/penalty
I have some java.sql.Time objects as follows: String s1 = 12:00:04; String s2 =
I have some legacy SQL (SP) declare @FactorCollectionId int; select @FactorCollectionId = collectionID from
I am doing some T-SQL programming and I have some Views defines on my
I have some records after SQL generating: YEARS MONTHS SUMMONTH SUMQUARTER QTR ----- ------
I have some data in an SQL table with an XML datatype column where
I have some code that uses the SQL Server 2005 SMO objects to backup
We have some unit tests running against a SQL server 2000 database using the

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.