Re: How to connect VB6 to SQL 2005 database?
- From: "Mark J. McGinty" <mmcginty@xxxxxxxxxxxxxxx>
- Date: Mon, 27 Feb 2006 08:10:10 -0800
"HK" <replywithingroup@xxxxxxxxxxx> wrote in message
news:ic%Lf.1527$h81.219@xxxxxxxxxxxxxxxxxxxxxxx
"MikeD" <nobody@xxxxxxxxxxx> wrote in message
news:uOQvAngOGHA.3100@xxxxxxxxxxxxxxxxxxxxxxx
[snip]
See the following:
Using SQL Express from Visual Basic 6
http://msdn.microsoft.com/vbrun/vbfusion/usingsqlexpress/
Very interesting article. The links in it were good as well, looks like the
new T-SQL features will come in handy, but...
I don't get what it says about MARS; specifically, the statement that it is
not possible to use one connection with more than one recordset, using SQL
2K (or SQL 7 for that matter.)
I have code deployed all over creation that proves otherwise -- including,
but not limited to, a [somewhat contrived] demo of a custom data source
control, that opens 2 recordsets containing the same records, but sorted in
opposite order. In a nutshell: "SELECT * FROM (" & UserSQL & ") drs ORDER
BY 1" for the first, and the same thing with " DESC" appended for the
second -- constructed to allow me to impose an arbitrary sort while neither
making assumptions about the user-entered SQL, nor jeaprodizing syntax.(*)
It is true that there are certain scenarios that make multiple use of a
connection counter-intuitive, and also true that lack of understanding those
scenarios can make attempting multiple use of a connection into a
frustrating ordeal... Avoiding the pitfalls of those scenarios may even be
challenging (for some -- that surely isn't my view) but impossible: it is
not... not by a damn sight.
And so I have to wonder what the basis for that statement was... and what
others in this ng thought about that end....
-Mark
(*) For those of you who may wish to point out that an ORDER BY clause in
UserSQL will break my derivation, it also injects " TOP 100 PERCENT " into
UserSQL, immediately after the first occurrence of SELECT, if the next word
is not already TOP -- again in the name of syntax preservation.
Mike
Microsoft MVP Visual Basic
That article says to download the 2.0 framework. Is that required? I
thought MDAC 2.8 would cover it.
.
- Prev by Date: ADO to SQL types
- Next by Date: Automatically running an application every day
- Previous by thread: ADO to SQL types
- Next by thread: Automatically running an application every day
- Index(es):
Relevant Pages
|
|