Discussion:
Transform Data Task and bit data type
(too old to reply)
Ajit
2004-04-20 07:01:03 UTC
Permalink
Hi
I want to export data from SQL server 2000 to text file. I am using Transform Data Task for the same
I am facing peiculiar problem in exporting columns which have 'bit' data type. In text files, the values for these columns appear as True/False instead of 1/0

How can I ensure presence of 0/1 instead of False/True for columns with bit datatype in destination text file

Thanks
Ajit
Allan Mitchell
2004-04-20 08:20:30 UTC
Permalink
How about converting to integer or string first?
--
----------------------------

Allan Mitchell MCSE,MCDBA, (Microsoft SQL Server MVP)
www.SQLDTS.com - The site for all your DTS needs.
I support PASS - the definitive, global community
for SQL Server professionals - http://www.sqlpass.org
Post by Ajit
Hi,
I want to export data from SQL server 2000 to text file. I am using
Transform Data Task for the same.
Post by Ajit
I am facing peiculiar problem in exporting columns which have 'bit' data
type. In text files, the values for these columns appear as True/False
instead of 1/0.
Post by Ajit
How can I ensure presence of 0/1 instead of False/True for columns with
bit datatype in destination text file?
Post by Ajit
Thanks,
Ajit
Ajit
2004-04-20 12:31:04 UTC
Permalink
This post might be inappropriate. Click to display it.
Allan Mitchell
2004-04-20 12:40:38 UTC
Permalink
Don't think so as the conversion to True/False is a feature of the driver
itself I believe.
--
----------------------------

Allan Mitchell MCSE,MCDBA, (Microsoft SQL Server MVP)
www.SQLDTS.com - The site for all your DTS needs.
I support PASS - the definitive, global community
for SQL Server professionals - http://www.sqlpass.org
Post by Ajit
Yes, converting helps. Only problem is for every bit field, select query
needs to be modified.
Post by Ajit
I was wondering if DTS gives control so that you make change at one place
and bit fields get exported as 0/1 only.
Post by Ajit
Thanks Allan for your reply.
Regards,
Ajit
----- Allan Mitchell wrote: -----
How about converting to integer or string first?
--
----------------------------
Allan Mitchell MCSE,MCDBA, (Microsoft SQL Server MVP)
www.SQLDTS.com - The site for all your DTS needs.
I support PASS - the definitive, global community
for SQL Server professionals - http://www.sqlpass.org
Post by Ajit
Hi,
I want to export data from SQL server 2000 to text file. I am using
Transform Data Task for the same.
Post by Ajit
I am facing peiculiar problem in exporting columns which have 'bit' data
type. In text files, the values for these columns appear as True/False
instead of 1/0.
Post by Ajit
Post by Ajit
How can I ensure presence of 0/1 instead of False/True for columns with
bit datatype in destination text file?
Post by Ajit
Post by Ajit
Thanks,
Ajit
Brandon
2010-08-25 17:05:41 UTC
Permalink
Sorry to hijack this, but it's the only thing I've found somewhat related to my problem with Google.

I've worked with Access exports and such for the last 4 years and never had to migrate data before now. Don't ask me why anyone would want to leave relational databases behind, but they are. Now I have to meet the import specifications of the developers and have the following problem.

1. I don't know DTS (SQLS 2000)
2. Currency datatypes always export with $
3. Bit types always export as True/False instead of 0/-1
4. For some reason two fields that hold decimal values get (") quotes around them.

I am trying to export to a text file in pipe delimited format, but when I try to run DTS on them there is no destination column to modify and when I try to define the tables. It crashes and closes down.

Any ideas would help.

Feel free to email me suggestions.

From http://www.developmentnow.com/g/103_2004_4_0_0_396071/Transform-Data-Task-and-bit-data-type.ht

Posted via DevelopmentNow.com Group
http://www.developmentnow.com/g/

Loading...