|
|
Well... the SqlDataReader is by no means a client side cursor... it's simply a TDS parser. That's what the dataset is for
Would be cool to check out the theory though... (how much locking does the TDS generator really support...) but as usual, I would probably never find the time.
Morty
|
|
|
|
|
Morten Abrahamsen wrote:
Well... the SqlDataReader is by no means a client side cursor... it's simply a TDS parser. That's what the dataset is for
Well, if it is a TDS parser it should be pretty fast! I think you're right, but some Anakrino hacking may solve this issue
Q261186 - Computer Randomly Plays Classical Music
|
|
|
|
|
Hehe... been there
However, this is not an issue dependant on the .NET SQL Client layer.
It's a question of how the SQL Server handles standard query processing.
If you issue a select query with a 100.000 record resultset, it would be returned as a datastream (TDS) to the client.
I would think that if there is no isolation (tx) there would just be a read lock on the current row (or index key) and not on the table, so records could easily be added or deleted. So if I'm correct the SQL Server would just read the data page by page and never precalculate the total amount and lock it. Hence the "imagined resultset" could be radically (add/delete) changed during the processing (which could take time), and a prior Count would be useless.
Just my 2c
|
|
|
|
|
I deduced the inserts would not be visible and deletes would by this: what would happen with a forward only cursor if I do a SELECT ... ORDER BY table_field and someone inserts data before my current cursor position?
Q261186 - Computer Randomly Plays Classical Music
|
|
|
|
|
I agree. If you do an order by and that order by is not the clustered index SQL Server would have to preprocess the entire dataset. (meaning the keys .. not necessarily the data).
However, it would be interesting to see what happens if you don't use a postprocessing instruction. (ORDER BY, GROUP BY, UNION, DISTINCT etc)
Morty
|
|
|
|
|
Hi I have the following table schema
Order(orderID, orderDate, creditCardNo, etc.....)
OrderedItem(OrderID(pk), ProductID(pk) )
Product(productId, productName ....etc.._
In access, when i delete the product from the Product table, if it is associated with a particular OrderedItem then i can not delete it, else i will be able to delete it.
However, I want to set it to ON DELETE SET NULL the ProductID in the OrderedItem
How will i do it?
Thanks
|
|
|
|
|
Hi,
I am trying to access password and aliases or for that matter every thing related to microsoft exchange users i am able to retrieve only usernames using mapi.session object,
Please help in retrieving other things if any body has code plesae post it here.
I have tried using ADSI also.
Thanks,
Amit Gupta
|
|
|
|
|
I would be very surprised if you were able to retrieve the user password using ANY form of API
|
|
|
|
|
I'd like to query and XML file with an SQL statement. Can this be done, or do I have to use XPath stuff? I've been perusing all sorts of CP code and MSDN stuff, and I can't seem to find an example of this, but I can't seem to find something that says I can't do this either.
Also, can the queries consist of a table join?
Thanks,
Marc
Help! I'm an AI running around in someone's f*cked up universe simulator.
|
|
|
|
|
Marc Clifton wrote:
Can this be done, or do I have to use XPath stuff?
I believe you have to use XPath, however SQL Server can return your "recordset" as an XML document. If that is any help to you.
Nick Parker
The greatest lesson in life is to know that even fools are right sometimes. - Winston Churchill
|
|
|
|
|
|
|
Is it possible create table WITH MY PROGRAM useing ADO.NET?
Mazy
"If I go crazy then will you still
Call me Superman
If I’m alive and well, will you be
There holding my hand
I’ll keep you by my side with
My superhuman might
Kryptonite"Kryptonite-3 Doors Down
|
|
|
|
|
Yes
Vagif Abilov
MCP (Visual C++)
Oslo, Norway
Hex is for sissies. Real men use binary. And the most hardcore types use only zeros - uppercase zeros and lowercase zeros.
Tomasz Sowinski
|
|
|
|
|
Yes, the easiest way is to issue a "CREATE TABLE ..." command
Dave.
|
|
|
|
|
dougieb wrote:
An extra $20 if you add parameters for 'first record to return from set', 'how many to return from set'
Save your $20 bucks and put a SELECT TOP X, where X is the record #.
No one will be able to give you a working solution without the tables. All you'll get is untested queries, and probably none will work and all of them will be slow.
Or, if you want, buy me a Amazon certificate.
Q261186 - Computer Randomly Plays Classical Music
|
|
|
|
|
I had a correct answer, so I tried to delete the thread as not to bug anyone else, but to no avail.
Thank you.
|
|
|
|
|
dougieb wrote:
As for the absence of tables, I'm pretty sure that generic tables could be made for testing purposes, or I figured that there would be some puzzle enthusiast who would just redo the syntax.
All I can say is good luck
Q261186 - Computer Randomly Plays Classical Music
|
|
|
|
|
I guess for a guy who's going to earn $60 it will be quite helpful to know data layout (tables, columns, column types, indices). Or do you think $60 should cover all guessing work too?
Vagif Abilov
MCP (Visual C++)
Oslo, Norway
Hex is for sissies. Real men use binary. And the most hardcore types use only zeros - uppercase zeros and lowercase zeros.
Tomasz Sowinski
|
|
|
|
|
This is my first run with SQL Server 2000. I have the server setup on my network, but when I go to "Register New Server" within Enterprise Agent, it's not listed. It's listed in the Win2k ODBC Admin tools (where you setup DSN's), but not within Enterprise Agent. There is a server showing up, but it is not mine. There are about 30 or so SQL server's out there (which, again, are listed where you setup ODBC in Win2K), but only one of these are showing up with I go to register a new server. What are some of the possible problems? I have verified protocol setup of TCP/IP for both server and client. Any help is appreciated!
|
|
|
|
|
I have seen this several times. Sometimes you jst have to type in the name of the server.
|
|
|
|
|
Is it possible to get a reference (pointer) to the actual data stored in a recordset, rather than a local copy? All the functions we have found return data by value. However, we want the fastest mechanism for getting at large volumes of data and so don't want to perform copies every time an item is accessed.
Thanks in advance!
Visit my website![^]
|
|
|
|
|
Connected recordset is the closest thing to actual data you can get. So if you have ADO Recordset object (not disconnected), you can call Update method to modify data. There is no way you can get a pointer to physical data. If you OLE DB directly (bypassing ADO), you can retrieve and modify data in a more efficient way.
Vagif Abilov
MCP (Visual C++)
Oslo, Norway
Hex is for sissies. Real men use binary. And the most hardcore types use only zeros - uppercase zeros and lowercase zeros.
Tomasz Sowinski
|
|
|
|
|
Thanks for your help, Vagif. It's a shame you can't get a pointer to the physical data. Nevermind. I guess your sig could say: ADO is for sissies. Real men use OLE DB. And the most hardcore types use only db library!!!
Cheers!
Visit my website![^]
|
|
|
|