April 2, 2003 at 9:21 am
PATIENT SUMMARY
Ref no : 1
Name : Mr A K
Age : 37 years
D.O.B. : 18.05.1965 Code No. : 64564564
Address : 8 Hurleston House Grove Street London
Post Code : SE1 3LC
--------------------------------------------------------------
--------------------------------------------------------------
PROBLEMS
--------------------------------------------------------------
I want to insert this record into a table with help of a format file and BCP. Can any one show me the way? I did try with format file but did not succeed.
April 2, 2003 at 9:35 am
Could you post what your bcp command when you tried it?
Patrick Birch
Quand on parle du loup, on en voit la queue
April 2, 2003 at 9:51 am
bcp dbname..tablename in B:\filename.txt -fb:\filename.fmt -Sservername -Uusename -Ppassword
Could you post what your bcp command when you tried it?
Patrick Birch
April 2, 2003 at 11:51 am
Can you also post the error message?
April 3, 2003 at 12:47 am
8.0
8
1SQLCHAR04"PATIENT SUMMARY\r\n\nEMIS no\t : " EmisNoLatin1_General
2SQLCHAR050"\rName\t : " NameLatin1_General
3SQLCHAR050"\rAge\t : " AgeLatin1_General
4SQLCHAR050"\rD.O.B.\t : " DateOfBirthLatin1_General
5SQLCHAR050" \tNHS No. : " NHSNoLatin1_General
6SQLCHAR050"\rAddress\t : " AddressLatin1_General
7SQLCHAR050"\rPost Code\t : " PostCodeLatin1_General
8SQLCHAR050"---\r---\r\rProblems\r---\r" ProblemsLatin1_General
this is the format file i created for the record i sent. but when i ran the BCP script it gave me an error as
Sqlstate=S1002, nativeerror=0
error=[microsoft][odbc sql server driver]Invalid Descriptor Index
April 8, 2003 at 8:34 am
Sqlstate=S1002, nativeerror=0
Reading BOL on SQLState it says that this an invalid column number. Check ODBC Error Messages.
Patrick Birch
Quand on parle du loup, on en voit la queue
Viewing 6 posts - 1 through 5 (of 5 total)
You must be logged in to reply to this topic. Login to reply