Showing posts with label spreadsheet. Show all posts
Showing posts with label spreadsheet. Show all posts

Wednesday, March 7, 2012

Null values when extracting data from an excel file

Hello,

I'm trying to import some data from a spreadsheet to a database table from a package in integration services. The problem is that I see the data when I open the excel file but when I try to run my package , it doesn't insert any rows in the table and it finishes with a success status.

My excel file has some formulas to get the data from other worksheets. I added a Data Viewer and all I see is null values in every cell.

I need help...does anyone know what's wrong?

This may seem to be obviuos; but meake sure you are pointing to the right sheet. What happens when you click the preview button in the Excel source?

Rafael Salas

|||It's the same thing... null values :(|||As soon as I close the Excel workbook containing links, I start getting NULLS through the dataflow.

When the workbook is open, the linked data works fine.|||

In my case, it happens in both situations, closed or opened. But it happens when I modify something in the sheet. I inserted some rows in blank and that's when I cannot read the data in SSIS. I still have the original file and I was able to import that specific sheet (before the change) to the database.

I did the same thing in another file(I′m looping through files) and it did OK, so I don't think the problem is the blank rows...

null values in sql server

Hi

I am importing an excel spreadsheet into tables in a sql server database using dts. I have one row of information filled out in the excel spreadsheet, but when the dts runs, it imports the information plus 5 extra rows filled with nulls ino the table.

Does anyone know how to fix this?

ThanksDid those rows have values in them previously but were erased? Here is an idea (I don't know if it will work). Try creating a new Excel Spreadsheet and cut-and-paste your valid rows from your original spreadsheet into the new spreadsheet, save it and try your DTS package again.|||Open the excel and remove the last 5 rows from the bottom which has null value.
I would rather prefer to save the excel sheet as .TXT file and then import the txt file.
Excel always seem to do something funny with the DTS.

Saturday, February 25, 2012

NULL Values

I imported an excel spreadsheet and it loaded a ton of records with NULL
values. When I try to delete them, it tells me To many rows will be
affected.
what is a SQL statement that I can type that will delete all the records
that has NULL in a particular field?DELETE FROM YourTable
WHERE YourColumn IS NULL
... and quit using EM to edit your data... it's not designed for that and
will definitely cause you problems in the long run (like this one)
"johnfli" <john@.here.com> wrote in message
news:OuGGCt7qEHA.3712@.TK2MSFTNGP15.phx.gbl...
> I imported an excel spreadsheet and it loaded a ton of records with NULL
> values. When I try to delete them, it tells me To many rows will be
> affected.
> what is a SQL statement that I can type that will delete all the records
> that has NULL in a particular field?
>
>|||what would you propose instead?
Thank you for your assistance.
"Adam Machanic" <amachanic@.hotmail._removetoemail_.com> wrote in message
news:OR333v7qEHA.3700@.TK2MSFTNGP15.phx.gbl...
> DELETE FROM YourTable
> WHERE YourColumn IS NULL
> ... and quit using EM to edit your data... it's not designed for that and
> will definitely cause you problems in the long run (like this one)
>
> "johnfli" <john@.here.com> wrote in message
> news:OuGGCt7qEHA.3712@.TK2MSFTNGP15.phx.gbl...
> > I imported an excel spreadsheet and it loaded a ton of records with NULL
> > values. When I try to delete them, it tells me To many rows will be
> > affected.
> > what is a SQL statement that I can type that will delete all the records
> > that has NULL in a particular field?
> >
> >
> >
>|||"johnfli" <john@.here.com> wrote in message
news:OgX4Ly7qEHA.3868@.TK2MSFTNGP15.phx.gbl...
> what would you propose instead?
> Thank you for your assistance.
Script your data modifications and run them from QA.|||I don't use sql that much, so I have no idea on how to write scripts to
import data from other files.
if you could assist me with that, that would be great.
I have a workbook with several sheets.
All sheets are the same format.
what would the script be? I have the table in sql all setup (there are
only 10 fields)
"Adam Machanic" <amachanic@.hotmail._removetoemail_.com> wrote in message
news:eVf3az7qEHA.556@.tk2msftngp13.phx.gbl...
> "johnfli" <john@.here.com> wrote in message
> news:OgX4Ly7qEHA.3868@.TK2MSFTNGP15.phx.gbl...
> > what would you propose instead?
> >
> > Thank you for your assistance.
> Script your data modifications and run them from QA.
>|||Try this article:
http://support.microsoft.com/?id=321686
"johnfli" <john@.here.com> wrote in message
news:uFZ04B8qEHA.348@.TK2MSFTNGP15.phx.gbl...
> I don't use sql that much, so I have no idea on how to write scripts to
> import data from other files.
> if you could assist me with that, that would be great.
> I have a workbook with several sheets.
> All sheets are the same format.
> what would the script be? I have the table in sql all setup (there are
> only 10 fields)
>

NULL Values

I imported an excel spreadsheet and it loaded a ton of records with NULL
values. When I try to delete them, it tells me To many rows will be
affected.
what is a SQL statement that I can type that will delete all the records
that has NULL in a particular field?
DELETE FROM YourTable
WHERE YourColumn IS NULL
... and quit using EM to edit your data... it's not designed for that and
will definitely cause you problems in the long run (like this one)
"johnfli" <john@.here.com> wrote in message
news:OuGGCt7qEHA.3712@.TK2MSFTNGP15.phx.gbl...
> I imported an excel spreadsheet and it loaded a ton of records with NULL
> values. When I try to delete them, it tells me To many rows will be
> affected.
> what is a SQL statement that I can type that will delete all the records
> that has NULL in a particular field?
>
>
|||what would you propose instead?
Thank you for your assistance.
"Adam Machanic" <amachanic@.hotmail._removetoemail_.com> wrote in message
news:OR333v7qEHA.3700@.TK2MSFTNGP15.phx.gbl...
> DELETE FROM YourTable
> WHERE YourColumn IS NULL
> ... and quit using EM to edit your data... it's not designed for that and
> will definitely cause you problems in the long run (like this one)
>
> "johnfli" <john@.here.com> wrote in message
> news:OuGGCt7qEHA.3712@.TK2MSFTNGP15.phx.gbl...
>
|||"johnfli" <john@.here.com> wrote in message
news:OgX4Ly7qEHA.3868@.TK2MSFTNGP15.phx.gbl...
> what would you propose instead?
> Thank you for your assistance.
Script your data modifications and run them from QA.
|||I don't use sql that much, so I have no idea on how to write scripts to
import data from other files.
if you could assist me with that, that would be great.
I have a workbook with several sheets.
All sheets are the same format.
what would the script be? I have the table in sql all setup (there are
only 10 fields)
"Adam Machanic" <amachanic@.hotmail._removetoemail_.com> wrote in message
news:eVf3az7qEHA.556@.tk2msftngp13.phx.gbl...
> "johnfli" <john@.here.com> wrote in message
> news:OgX4Ly7qEHA.3868@.TK2MSFTNGP15.phx.gbl...
> Script your data modifications and run them from QA.
>
|||Try this article:
http://support.microsoft.com/?id=321686
"johnfli" <john@.here.com> wrote in message
news:uFZ04B8qEHA.348@.TK2MSFTNGP15.phx.gbl...
> I don't use sql that much, so I have no idea on how to write scripts to
> import data from other files.
> if you could assist me with that, that would be great.
> I have a workbook with several sheets.
> All sheets are the same format.
> what would the script be? I have the table in sql all setup (there are
> only 10 fields)
>