LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #11   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 74
Default Convert Format of SQL Data

K Dales wrote:
I think there is a fundamental problem with this request: SQL has

no
boolean data type.


Thanks for pointing this out: I don't work directly with T-SQL so I

was not
aware of this limitation; I did mention that the actual formula would

be
dependent on the implementation of SQL used. However any formula

accepted by
T-SQL should work, and I am pretty sure there must be some formula

that will
yield the proper result.


Trying to be sneaky here... Rather than using a SQL Server connection,
I instead connected to the workbook, i.e. used a MS Jet connection
which *does* support a BOOLEAN data type, then used Jet's ODBC
pass-through functionality to connect to the SQL Server table then cast
as a Boolean in Jet e.g.

SELECT IIF(MyBitCol<0,TRUE,FALSE)
FROM [ODBC;DSN=SQLServer_Airplanes].MyTable;

No luck, though. MS Query still returned the values to the worksheet as
numeric values.

Jamie.

--

 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Convert data into proper time format [email protected] Excel Worksheet Functions 1 April 25th 06 07:39 PM
How do I convert numeric data to string format (without VBA)? LissaC Excel Worksheet Functions 1 March 20th 06 07:44 PM
Import csv data and convert to TIME format JLettington Excel Worksheet Functions 0 January 25th 06 03:34 PM
How do I convert word data (not in tables) into excel format? resret29 Excel Worksheet Functions 2 October 9th 05 01:25 AM
CONVERT DATA TO CURRENCY FORMAT roy in sunbury Excel Discussion (Misc queries) 1 January 12th 05 03:12 AM


All times are GMT +1. The time now is 01:14 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"