Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
Author |
Topic |
vasu4us
Posting Yak Master
102 Posts |
Posted - 2009-02-23 : 11:21:22
|
Hi all,I have a package which transfers data from a SQL server table to another SQL server table.Everything workers but there is a column declared as BOOLEAN 0 and 1 as values in it.When it is moved to the other table I get to see -1 and 0.I tried to use a data conversion but no use.Any help will be appreciated. Thanks,Vasu |
|
yosiasz
Master Smack Fu Yak Hacker
1635 Posts |
Posted - 2009-02-23 : 12:00:25
|
This might help? http://www.sqlteam.com/forums/topic.asp?TOPIC_ID=99757. |
 |
|
vijayisonly
Master Smack Fu Yak Hacker
1836 Posts |
Posted - 2009-02-23 : 12:12:20
|
As far as I know there is no BOOLEAN data type in SQL Server. Is it a BIT type field? Whats the exact data type of this field on the other table that you are moving to? |
 |
|
vasu4us
Posting Yak Master
102 Posts |
Posted - 2009-02-23 : 13:11:13
|
Yes its a BIT data type and in ssis its is displayed as BOOLEAN (DT_BOOL) this column is going into a column of type INT. |
 |
|
vasu4us
Posting Yak Master
102 Posts |
Posted - 2009-02-23 : 15:05:40
|
Please ignore the above request.I was informed incorrectly.Here is the actual pictureI have a Bit type column with 0/1 in it. I am moving date outof a query to a DAT file using SSIS, this column with 0/1 is coming in as 0/-1 in the DAT file.where exactly should i be changing or converting the type?in the oledb source if i go to adv-editor--> input/output propertiesthat column type is shown as four-byte signed int(DTI4)in external columns and output columns. |
 |
|
vasu4us
Posting Yak Master
102 Posts |
Posted - 2009-02-23 : 15:06:16
|
Please ignore the above request.I was informed incorrectly.Here is the actual pictureI have a Bit type column with 0/1 in it. I am moving date out of a query to a DAT file using SSIS, this column with 0/1 is coming in as 0/-1 in the DAT file.where exactly should i be changing or converting the type?in the oledb source if i go to adv-editor--> input/output propertiesthat column type is shown as four-byte signed int(DTI4)in external columns and output columns. |
 |
|
vijayisonly
Master Smack Fu Yak Hacker
1836 Posts |
Posted - 2009-02-23 : 15:24:27
|
OK...when you say "I am moving date out of a query to a DAT file using SSIS"..how exactly are you valuing this field in the DAT file?Are you not using a OLE DB source to a Flat File conneciton?And the data type for the field in the DAT file is also DTI4? |
 |
|
vasu4us
Posting Yak Master
102 Posts |
Posted - 2009-02-23 : 15:33:56
|
I am using a OLEDB SOURCE to date file destination.The query in the oledb source has the column that i am having problem with. the column is declared as BIT in the source table.when in copy past that query in the OLEDB source query and check the data types in the advance editor i get to see four-byte signed int.when i add a data viewer to see the output i get to see -1 in place of 1. |
 |
|
|
|
|