microsoft / microsoft/sql-server-samples

Error @ Bulk Insert

Open
#743 2 comments 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
PowerShell
Stars
11.2k
Forks
9.1k
Avg merge
2d 7h
Merged PRs (30d)
14

Description

Hi,
While I was trying to run the script to install Adventure Works DB, I came across an error when Bulk Insert script tries to run, as it had an issue with the columns and rows not being properly identified or terminated.

So the work around that I used was a very lame one, but it worked. I just replaced the following line for some tables but not all.

ROWTERMINATOR = '\n', (replaced '\n' with '0x0a') This workaround worked for me.

For other tables where

ROWTERMINATOR='&|\n', (this line worked)

So just in case, anyone came across with bulk error, they can use this workaround.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the Adventure Works DB installation script and locate the BULK INSERT statements using ROWTERMINATOR. Compare the affected table definitions and input files to determine why row and column termination is inconsistent. Done means the installation script completes successfully for the affected tables without relying on an undocumented workaround.

Written by the indexing model from the issue text.

Assessment

Tech stack
sql
Domain
databases
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.