I hope Microsoft is listening

  • Thread starter Thread starter Keith K
  • Start date Start date
And I was sitting here thinking all the :4m3 Script Kiddy's were asleep.

Is this a joke? What DDL haven't you been able to accomplish with ADO.NET?
Perhaps I have had a few too many Bud Lights this evening, but I'll publicly
state that I'll give you $10.00 for every DDL command that is supported by
ANSI SQL and I can't do with ADO.NET <even after 6 Remy's> .... At least
Keith, if you have a valid gripe against MS, post it and let them respond.
They aren't beyond reproach, but at least give them a fair trial and jury of
their peers.

More seriously, if you need any help with executing DDL, I'll be somewhat
sober by 8:00 EDT tomorrow (optimistically) and will do whatever I can to
help you.

Cheers,

Bill
 
Hell, just to prove a point, make it $50.00
William Ryan said:
And I was sitting here thinking all the :4m3 Script Kiddy's were asleep.

Is this a joke? What DDL haven't you been able to accomplish with ADO.NET?
Perhaps I have had a few too many Bud Lights this evening, but I'll publicly
state that I'll give you $10.00 for every DDL command that is supported by
ANSI SQL and I can't do with ADO.NET <even after 6 Remy's> .... At least
Keith, if you have a valid gripe against MS, post it and let them respond.
They aren't beyond reproach, but at least give them a fair trial and jury of
their peers.

More seriously, if you need any help with executing DDL, I'll be somewhat
sober by 8:00 EDT tomorrow (optimistically) and will do whatever I can to
help you.

Cheers,

Bill
 
Len:

CREATE Database is supported by ADO.NET. Youi can do it with SQL Server,
Oracle and MySQL --- so it an issue with Access, but you can't rightly claim
that ADO.NET doesn't support DDL. I've never tried it with Access so
perhaps you can't, but that's not something ADODDL.net or whatever old boy
wanted would address
 
o.k. here goes:

In adox I can retrieve information related to a column
such as its "default" value. I also can retrieve info on
indexes such as which columns in a particular table are in
a non-clustered index. Also I want to loop through the
properties and attributes of a column. I also want to
address security. All of this without having to create
Oracle specific SQL, Sybase specific SQL, Access specific
SQL, and SQL Server specific SQL. I'm totally abstracted
from that.

Microsoft's definition:
==========================
Microsoft ActiveX Data Objects Extensions for Data
Definition Language and Security (ADOX) is an extension to
the ADO objects and programming model. ADOX includes
objects for schema creation and modification, as well as
security. Because it is an object-based approach to schema
manipulation, you can write code that will work against
various data sources regardless of differences in their
native syntaxes.

ADOX is a companion library to the core ADO objects. It
exposes additional objects for creating, modifying, and
deleting schema objects, such as tables and procedures. It
also includes security objects to maintain users and
groups and to grant and revoke permissions on objects.
=================


Besides, Len is correct and should get his $50. Access is
Microsoft's product as well. They know that there are a
substantial number of Access developers out there trying
to use .NET with Jet. CREATE Database is addressed in
adox (even against Access)! I guess they just forgot to
put that in ADO.NET huh? These are very real issues that
many of us face because I do quite a bit of Jet-DB
development as well as smaller customers like it and can
afford it. Heck, for that matter, adox should have never
been created in the first place because I could just as
easily perform DDL using ADO.
 
Keith:

First off, my apologies for the tone of my original response. I incorrectly
asssumed your original post was a .NET Sucks becuase you can't do X even
though you can. Clearly this isn't the case.

To the extent that everytyhing be generic, all of your points are valid.
However, that's not to say that for any given task that you need to
implement with DDL, that you can't do it with ADO.NET. You can in fact
create an Index, clustered or non-clustered on a SQL Server DB for instance.
The fact that you can't generically grab all the information from all db
types about indexes is a different issue. DDL Constructs like Create
Table, Create View, Grant, Revoke, Drop are all supported with ADO.NET.
That was the point I was initially making, and while I stand by that, this
wasn't what you were addressing.

As far as Access goes, you're both right that ADOX is the only way to grab
it. However, ADO.NET does support creating databases. The fact you can do
it with most other RDBMS but not access doesn't make it OK, particularly
from the point of an Access developer, but there's a fundamental difference
between not being able to do something for one system , and not being able
to do it at all.

We were arguing different points and it was my misunderstanding. To that
end, my apologies.

Bill
 
¤ o.k. here goes:
¤
¤ In adox I can retrieve information related to a column
¤ such as its "default" value. I also can retrieve info on
¤ indexes such as which columns in a particular table are in
¤ a non-clustered index. Also I want to loop through the
¤ properties and attributes of a column. I also want to
¤ address security. All of this without having to create
¤ Oracle specific SQL, Sybase specific SQL, Access specific
¤ SQL, and SQL Server specific SQL. I'm totally abstracted
¤ from that.
¤

Unfortunately no can do. You can use the OLEDB provider with GetOleDbSchemaTable but that is about
as generic as it gets. You still need a vendor or database specific provider.

You have to understand that databases have different implementations - not all will require the same
mechanism by which schema information can be retrieved. A perfect is example is
autonumber/autoincrement fields. Both SQL Server and Access implement them similarly. Oracle uses
what is referred to as a "sequence". Information about an Oracle sequence cannot be retrieved by way
of a column property.

There would no feasible way for Microsoft to support a generic mechanism for all database types
without forcing the vendors to *fully* comply with a common standard.


Paul ~~~ (e-mail address removed)
Microsoft MVP (Visual Basic)
 
-----Original Message-----
¤ o.k. here goes:
¤
¤ In adox I can retrieve information related to a column
¤ such as its "default" value. I also can retrieve info on
¤ indexes such as which columns in a particular table are in
¤ a non-clustered index. Also I want to loop through the
¤ properties and attributes of a column. I also want to
¤ address security. All of this without having to create
¤ Oracle specific SQL, Sybase specific SQL, Access specific
¤ SQL, and SQL Server specific SQL. I'm totally abstracted
¤ from that.
¤

Unfortunately no can do. You can use the OLEDB provider
with GetOleDbSchemaTable but that is about
as generic as it gets. You still need a vendor or database specific provider.

You have to understand that databases have different
implementations - not all will require the same
mechanism by which schema information can be retrieved. A perfect is example is
autonumber/autoincrement fields. Both SQL Server and
Access implement them similarly. Oracle uses
what is referred to as a "sequence". Information about an
Oracle sequence cannot be retrieved by way
of a column property.

There would no feasible way for Microsoft to support a
generic mechanism for all database types
without forcing the vendors to *fully* comply with a common standard.


Paul ~~~ (e-mail address removed)
Microsoft MVP (Visual Basic)
.

Thanks for you input. I'm aware of the need for a vendor-
specific data provider. That's not an issue for me
because I have native providers for Oracle, Sybase and SQL
Server.
 
Keith,

I have never tried it but I believe you can still use
ADOX by creating a reference to it.

In the Add Reference dialog, COM tab, select:

Microsoft ADO Ext. 2.7 for DDL and Security.

Bob Costello
 
In .NET you can use the OleDb provider like so:

OleDbConnection cn = new OleDbConnection("Provider=SQLOLEDB;yada,
yada");
cn.Open();
DataTable schemaTable = cn.GetOleDbSchemaTable(OleDbSchemaGuid.Views,
null);

Also, look in your SQL Server's master database, in the views section
at the Information Schema Views.



 
Back
Top