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 1032451
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 16, 20262026-05-16T14:04:44+00:00 2026-05-16T14:04:44+00:00

I have tried many things, but I’m still not getting this to work. Here’s

  • 0

I have tried many things, but I’m still not getting this to work. Here’s the code:

bcp RFID.dbo.ResultsDump format nul -t, -c -x -f C:\RFID.xml -S"ALBERTLAST-PC\SQLEXPRESS" -UAlbert Last -P -T

All I want to do is create an XML format file from ResultsDump table, and the above statement doesn’t even work. My username is “Albert Last” where Last is my last name, yet this is what the above statement returns:

bcp:  unknown option A
usage: bcp {dbtable | query} {in | out | queryout | format} datafile
  [-m maxerrors]            [-f formatfile]          [-e errfile]
  [-F firstrow]             [-L lastrow]             [-b batchsize]
  [-n native type]          [-c character type]      [-w wide character type]
  [-N keep non-text native] [-V file format version] [-q quoted identifier]
  [-C code page specifier]  [-t field terminator]    [-r row terminator]
  [-i inputfile]            [-o outfile]             [-a packetsize]
  [-S server name]          [-U username]            [-P password]
  [-T trusted connection]   [-v version]             [-R regional enable]
  [-k keep null values]     [-E keep identity values]
  [-h "load hints"]         [-x generate xml format file]
NULL

It’s thinking that I am asking for option A, because when I put square brackets around Albert Last, here’s what I get:

bcp:  unknown option [

I’ve also tried this WITHOUT specifying server name, username, or password, with just -T. This is what I get:

SQLState = 37000, NativeError = 4060
Error = [Microsoft][SQL Native Client][SQL Server]Cannot open database "RFID" requested by the login. The login failed.
SQLState = 28000, NativeError = 18456
Error = [Microsoft][SQL Native Client][SQL Server]Login failed for user 'NT AUTHORITY\NETWORK SERVICE'.
NULL

I’ve looked everywhere online and have not seen a similar problem before, and I’m beginning to think that this is just a simple mistake that I’m not catching.

Can somebody help?? Or if there is a way to generate format xml file RFID.xml from table ResultsDump without bcp, that would be greatly appreciated! Thanks in advance!

  • 1 1 Answer
  • 1 View
  • 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-05-16T14:04:44+00:00Added an answer on May 16, 2026 at 2:04 pm

    Can you try if the following works:

    -U"Albert Last"
    

    I can vaguely remember that I have done it this way a long time ago.

    The error you see in your comment has something to do with your format file (c:\RFID.xml), not with your username. Possibly you do not have write access to c:\? Can you try it with a relative path, just RFID.xml? And make sure you then run the bcp command from a location where you have write access.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have tried many things to get this working correctly but I can't Here
Before posting this question, I have tried so many things but that was not
Yes, I have searched and tried many techniques, but nothing seems to work. Here
Here is very tricky situation i have tried many things but cant figure it
I have tried so many things but I don't understand this sooo confusing. I
i have tried many things to solve this but none worked. im trying to
I tried many things but not successful :( I have two sortable lists connected
I have tried many combinations of things but with no joy. Here is what
I have tried so many things but I could not found How I can
I have tried so many things, cannot figure this out, I am using this

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.