Results 1 to 9 of 9

Thread: SQL Server 2005..

  1. #1
    Sublime HEXUS.net
    Join Date
    Jul 2003
    Location
    The Void.. Floating
    Posts
    11,819
    Thanks
    213
    Thanked
    233 times in 160 posts
    • Stoo's system
      • Motherboard:
      • Mac Pro
      • CPU:
      • 2*Xeon 5450 @ 2.8GHz, 12MB Cache
      • Memory:
      • 32GB 1600MHz FBDIMM
      • Storage:
      • ~ 2.5TB + 4TB external array
      • Graphics card(s):
      • ATI Radeon HD 4870
      • Case:
      • Mac Pro
      • Operating System:
      • OS X 10.7
      • Monitor(s):
      • 24" Samsung 244T Black
      • Internet:
      • Zen Max Pro

    SQL Server 2005..

    Is anyone using this currently?

    I'm having major issues transitioning our 2000 DTS packages over to 2005, 2005 just doesn't seem to want to import the data, bugging out every time with the error:

    "cannot convert between unicode and non-unicode string data types."

    In fact, I get the exact same error trying to do it from scratch with the import wizard to create a brand new SSIS package.

    This is the data file I'm trying to import, it's vertical bar delimited, with mac style {cr} only row delimiters (this isn't an issue at all in SQL Server 2000).

    This is the table it goes into:
    Code:
    	[ID] [int] IDENTITY(1,1) NOT NULL,
    	[SiteCode] [nvarchar](50) COLLATE Latin1_General_CI_AS NULL,
    	[SiteName] [nvarchar](50) COLLATE Latin1_General_CI_AS NULL,
    	[SiteType] [nvarchar](50) COLLATE Latin1_General_CI_AS NULL,
    	[Country] [nvarchar](50) COLLATE Latin1_General_CI_AS NULL,
    	[Region] [nvarchar](50) COLLATE Latin1_General_CI_AS NULL,
    	[Area] [nvarchar](50) COLLATE Latin1_General_CI_AS NULL,
    	[County] [nvarchar](50) COLLATE Latin1_General_CI_AS NULL,
    	[Place] [nvarchar](50) COLLATE Latin1_General_CI_AS NULL,
    	[PageNumber] [nvarchar](50) COLLATE Latin1_General_CI_AS NULL,
    	[SiteDesc] [ntext] COLLATE Latin1_General_CI_AS NULL,
    	[SiteFeatures] [ntext] COLLATE Latin1_General_CI_AS NULL,
    	[Airport] [nvarchar](50) COLLATE Latin1_General_CI_AS NULL,
    	[Note] [ntext] COLLATE Latin1_General_CI_AS NULL,
    	[VTEnabled] [nvarchar](50) COLLATE Latin1_General_CI_AS NULL,
    	[IndoorOutdoor] [nvarchar](80) COLLATE Latin1_General_CI_AS NULL,
    	[IO_Text] [ntext] COLLATE Latin1_General_CI_AS NULL,
    	[SpecialHead] [nvarchar](80) COLLATE Latin1_General_CI_AS NULL,
    	[SpecialText] [ntext] COLLATE Latin1_General_CI_AS NULL
    Am I correct in thinking that 2005 is being far more specific with it's table formatting, which is then causing an issue when I try to import that data into the existing table?
    (\__/)
    (='.'=)
    (")_(")

  2. #2
    Anthropomorphic Personification shaithis's Avatar
    Join Date
    Apr 2004
    Location
    The Last Aerie
    Posts
    10,857
    Thanks
    645
    Thanked
    872 times in 736 posts
    • shaithis's system
      • Motherboard:
      • Asus P8Z77 WS
      • CPU:
      • i7 3770k @ 4.5GHz
      • Memory:
      • 32GB HyperX 1866
      • Storage:
      • Lots!
      • Graphics card(s):
      • Sapphire Fury X
      • PSU:
      • Corsair HX850
      • Case:
      • Corsair 600T (White)
      • Operating System:
      • Windows 10 x64
      • Monitor(s):
      • 2 x Dell 3007
      • Internet:
      • Zen 80Mb Fibre
    Just as a test.....have you tried importing them into a table with the fields defined as non-unicode? i.e. remove all the n's from ntext, nvarchar etc.
    Main PC: Asus Rampage IV Extreme / 3960X@4.5GHz / Antec H1200 Pro / 32GB DDR3-1866 Quad Channel / Sapphire Fury X / Areca 1680 / 850W EVGA SuperNOVA Gold 2 / Corsair 600T / 2x Dell 3007 / 4 x 250GB SSD + 2 x 80GB SSD / 4 x 1TB HDD (RAID 10) / Windows 10 Pro, Yosemite & Ubuntu
    HTPC: AsRock Z77 Pro 4 / 3770K@4.2GHz / 24GB / GTX 1080 / SST-LC20 / Antec TP-550 / Hisense 65k5510 4K TV / HTC Vive / 2 x 240GB SSD + 12TB HDD Space / Race Seat / Logitech G29 / Win 10 Pro
    HTPC2: Asus AM1I-A / 5150 / 4GB / Corsair Force 3 240GB / Silverstone SST-ML05B + ST30SF / Samsung UE60H6200 TV / Windows 10 Pro
    Spare/Loaner: Gigabyte EX58-UD5 / i950 / 12GB / HD7870 / Corsair 300R / Silverpower 700W modular
    NAS 1: HP N40L / 12GB ECC RAM / 2 x 3TB Arrays || NAS 2: Dell PowerEdge T110 II / 24GB ECC RAM / 2 x 3TB Hybrid arrays || Network:Buffalo WZR-1166DHP w/DD-WRT + HP ProCurve 1800-24G
    Laptop: Dell Precision 5510 Printer: HP CP1515n || Phone: Huawei P30 || Other: Samsung Galaxy Tab 4 Pro 10.1 CM14 / Playstation 4 + G29 + 2TB Hybrid drive

  3. #3
    Sublime HEXUS.net
    Join Date
    Jul 2003
    Location
    The Void.. Floating
    Posts
    11,819
    Thanks
    213
    Thanked
    233 times in 160 posts
    • Stoo's system
      • Motherboard:
      • Mac Pro
      • CPU:
      • 2*Xeon 5450 @ 2.8GHz, 12MB Cache
      • Memory:
      • 32GB 1600MHz FBDIMM
      • Storage:
      • ~ 2.5TB + 4TB external array
      • Graphics card(s):
      • ATI Radeon HD 4870
      • Case:
      • Mac Pro
      • Operating System:
      • OS X 10.7
      • Monitor(s):
      • 24" Samsung 244T Black
      • Internet:
      • Zen Max Pro
    Hmmm.. I beginning to suspect that it's the table at fault rather than the data.. can't check now until tomorrow, but it gives me a place to look.. cheers

    Having said that, it was coming up with some weirdness on the data preview of the flat file connection.. (trying to start the next row in the end 2 columns..)
    (\__/)
    (='.'=)
    (")_(")

  4. #4
    TiG
    TiG is offline
    Walk a mile in other peoples shoes...
    Join Date
    Jul 2003
    Location
    Questioning it all
    Posts
    6,213
    Thanks
    43
    Thanked
    47 times in 42 posts
    Erm are you importing this as a txt file, i've used 2005 a fair bit now, but still not got it 100% down from memory. Isn't there an option to open the file as a different format, (not Windows ANSI) but Unicode instead, this hopefully should handle the solution better?.

    If not i can try at work tomorrow if you are still having issues.

    TiG
    -- Hexus Meets Rock! --

  5. #5
    Sublime HEXUS.net
    Join Date
    Jul 2003
    Location
    The Void.. Floating
    Posts
    11,819
    Thanks
    213
    Thanked
    233 times in 160 posts
    • Stoo's system
      • Motherboard:
      • Mac Pro
      • CPU:
      • 2*Xeon 5450 @ 2.8GHz, 12MB Cache
      • Memory:
      • 32GB 1600MHz FBDIMM
      • Storage:
      • ~ 2.5TB + 4TB external array
      • Graphics card(s):
      • ATI Radeon HD 4870
      • Case:
      • Mac Pro
      • Operating System:
      • OS X 10.7
      • Monitor(s):
      • 24" Samsung 244T Black
      • Internet:
      • Zen Max Pro
    Yup, straight import as a text file (the text file in question is linked up there ^), I did try checking the unicode import option, but then it couldn't find the row/column delimiters..

    I tried changing the code page to "MAC Roman" on one attempt too, but no dice..

    I did copy the database across from the 2000 developer edition initially, then then I did a drop/create operation in the SSIS package, so the table structure should have been even more basic than the above SQL (I think the script table to clipboard operation added a few more bits - I posted it just as I was going out of the door last night).

    I'll have another play with it when I get in today..
    (\__/)
    (='.'=)
    (")_(")

  6. #6
    TiG
    TiG is offline
    Walk a mile in other peoples shoes...
    Join Date
    Jul 2003
    Location
    Questioning it all
    Posts
    6,213
    Thanks
    43
    Thanked
    47 times in 42 posts
    It doesn't look like its anything to do with the table to me, it looks like the data vs the codepage of the text you are importing. For a start i'll tell you now its not SQL Safe. That is i'd never consider having things like the following...

    Cromer's
    Code:
    Cromer& #39;s
    inside a database.

    I've got it to import some data but as with SSIS you can't do manipulation of the import in the bulk insert task i'm afraid i'm stuck and i've not enough knowledge with SSIS yet to know the best way to get around this.

    Don't know if thats helps but thats as far as i've got.

    TiG
    -- Hexus Meets Rock! --

  7. #7
    Administrator Moby-Dick's Avatar
    Join Date
    Jul 2003
    Location
    There's no place like ::1 (IPv6 version)
    Posts
    10,665
    Thanks
    53
    Thanked
    384 times in 313 posts
    not got my sql 2k5 install up yet
    my Virtualisation Blog http://jfvi.co.uk Virtualisation Podcast http://vsoup.net

  8. #8
    Sublime HEXUS.net
    Join Date
    Jul 2003
    Location
    The Void.. Floating
    Posts
    11,819
    Thanks
    213
    Thanked
    233 times in 160 posts
    • Stoo's system
      • Motherboard:
      • Mac Pro
      • CPU:
      • 2*Xeon 5450 @ 2.8GHz, 12MB Cache
      • Memory:
      • 32GB 1600MHz FBDIMM
      • Storage:
      • ~ 2.5TB + 4TB external array
      • Graphics card(s):
      • ATI Radeon HD 4870
      • Case:
      • Mac Pro
      • Operating System:
      • OS X 10.7
      • Monitor(s):
      • 24" Samsung 244T Black
      • Internet:
      • Zen Max Pro
    Ahh, I've not tried using the bulk insert task, I'm using the flatfile source > Data conversion > Data Flow Task method at the moment..

    I've also tried it from the import/export SSIS wizard, and still no joy..

    tbh, it looks like 2005 needs a good usability patching, 2000 was far more intuitive..
    Last edited by Stoo; 01-02-2006 at 04:23 PM.
    (\__/)
    (='.'=)
    (")_(")

  9. #9
    Sublime HEXUS.net
    Join Date
    Jul 2003
    Location
    The Void.. Floating
    Posts
    11,819
    Thanks
    213
    Thanked
    233 times in 160 posts
    • Stoo's system
      • Motherboard:
      • Mac Pro
      • CPU:
      • 2*Xeon 5450 @ 2.8GHz, 12MB Cache
      • Memory:
      • 32GB 1600MHz FBDIMM
      • Storage:
      • ~ 2.5TB + 4TB external array
      • Graphics card(s):
      • ATI Radeon HD 4870
      • Case:
      • Mac Pro
      • Operating System:
      • OS X 10.7
      • Monitor(s):
      • 24" Samsung 244T Black
      • Internet:
      • Zen Max Pro
    After much messing around, I've finally got it to import *most* of the data, and managed to get it to dump out the problematic rows..

    I've imported the text into excel, then imported the excel file, before it was only importing every other line (even though I've specified it, it can't see it half the time!), this time it's importing all but a few problematic rows.

    I really don't know why 2005 is being such a pain in the butt, when 2000 was pretty much flawless... *sulk*
    (\__/)
    (='.'=)
    (")_(")

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. MS launches SQL Server 2005, Visual Studio
    By Steve in forum HEXUS News
    Replies: 4
    Last Post: 07-11-2005, 12:33 PM
  2. SQL Server Connection string?
    By Stoo in forum Software
    Replies: 7
    Last Post: 04-05-2005, 05:48 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •