|
Interesting, thanks. Sounds like a lot of work, but hey.
What do you think of the solution of 1 initial query (to get all common Foo data), then an extra query each time you want to retrieve a FooInheritor?
|
|
|
|
|
If the data is for display to a human and the database calls are not across the internet via dialup, then the performance should be OK (and I am talking about the case of maybe dozens of individual foo-inheritor queries). If it is for some kind of automated data collection and reporting, then the performance could be an issue if you end up making a hundred queries each second.
As always, the best solution depends on all the little details, so it is not easy to recommend one solution over another. Each has its own implications for maintenance and performance. Think about it, then choose one way to do it, and just do it. Try to burry the details in an assembly and access it through an interface. If the implementation starts to cause problems, redesign it later, and the code accessing the interface will not need to be changed; just recompile the implementation assembly, convert the database, and you are done.
Scott
|
|
|
|
|
It is for display for a human.
I'm thinking I will go with the multiple queries thing and see how it goes.
Thanks for your in-depth answers, much appreciated.
|
|
|
|
|
Hi All;
I have a dataGridView binding to a dataView. I change the row filter of dataview on textChange of a textbox and it works very fine but the problem arises when i add the datatable (from which the dataview has been created) in a dataset, RowFilter stops working... any clue?
sorry for my bad English.
|
|
|
|
|
Why you have a DataTable without a DataSet? It does not matter. I dont know, why the RowFilter stops working, but try to use the Select-Method from DataTable instead a DataView.RowFilter.
Regards
Stephan
\\\| \\ - -
( @ @ )
+---------------oOOo-(_)-oOOo-----------------+
| Stephan Pilz stephan.pilz@stephan-pilz.de |
| <a href=www.stephan-pilz.de>www.stephan-pilz.de</a> |
| ICQ#: 127823481 |
+-----------------------Oooo------------------+
oooO ( )
( ) ) /
\ ( (_/
\_)
|
|
|
|
|
hi,
Is there a way to invoke in .net the visual Query Builder but in your running application,
not in design mode. If it is possible please tell me how, cause i can't seem to find the
corresponding control
Thanks Kurt
codito ergo sum
|
|
|
|
|
how to declare,fetch,deallocate and manipulate using cursor in SQL SERVER
|
|
|
|
|
choorakkuttyil wrote: how to declare
DECLARE cursor_name CURSOR
[LOCAL | GLOBAL]
[FORWARD_ONLY | SCROLL]
[STATIC | KEYSET | DYNAMIC | FAST_FORWARD]
[READ_ONLY | SCROLL_LOCKS | OPTIMISTIC]
[TYPE_WARNING]
FOR select_statement
[FOR UPDATE [OF column_name [,...n]]]
opening a cursor:===
OPEN { { [GLOBAL] cursor_name } | cursor_variable_name}
choorakkuttyil wrote: fetch
FETCH
[ [ NEXT | PRIOR | FIRST | LAST
| ABSOLUTE {n | @nvar}
| RELATIVE {n | @nvar}
]
FROM
]
{ { [GLOBAL] cursor_name } | @cursor_variable_name}
[INTO @variable_name[,...n] ]
choorakkuttyil wrote: deallocate
DEALLOCATE { { [GLOBAL] cursor_name } | @cursor_variable_name}
Best Regards,
Apurva Kaushal
|
|
|
|
|
SQL Server Books Online:
Using Cursors[^]
Declare Cursor (T-SQL)[^]
Example:
CREATE PROCEDURE MyProcedure @cMyParameter varchar(100)
AS
DECLARE @cMyVar varchar(100)
DECLARE mycursor CURSOR FOR
SELECT MyField
FROM MyTable
WHERE MyOtherField = @cMyParameter
OPEN mycursor
FETCH NEXT FROM mycursor INTO @cMyVar
WHILE @@FETCH_STATUS = 0
BEGIN
FETCH NEXT FROM mycursor INTO @cMyVar
--do some processing
END
CLOSE mycursor
DEALLOCATE mycursor
--EricDV Sig---------
Some problems are so complex that you have to be highly intelligent and well informed just to be undecided about them.
- Laurence J. Peters
|
|
|
|
|
I want to use report services in SQL server 2005 express edition. Does it require IIS?
Thanks
|
|
|
|
|
I'm not sure about the Express Edition, but Reporting Services, in general, requires IIS, at least 5.0, and ASP.NET 2.0.
Dave Kreskowiak
Microsoft MVP - Visual Basic
|
|
|
|
|
Does anybody know what we need to read out an Access database?
Is MS Access really needed or can you install a provider only (or Access only without the rest of Office)? We need to show the data in our application only. (the users don't have to open the file itself) Currently the client provided the data in a mdb file, which occasionaly can be updated. Unfortunately this application has to be installed on several hundreds of workstations where Office is not installed.
The application is a html application embedded in our product. I use javascript to access the db.
Thanks a lot for your help...
|
|
|
|
|
V. wrote: has
The MS access oledb provide (ADO0) is intalled with the system in in "program files\common files\system\ADO"
The Jet engine dllas are normally around in windows\system32
As a result, you should not have to intall anything if you are using ADO/ADO.Net to read from the file.
If these are old clients (win2k, ME, Win98 etc.) you may need to install ADO and possibly the jet engine stuff.
Redistributables can be found here[^]
|
|
|
|
|
Hey man,
thanks a lot, this is really helpfull !
|
|
|
|
|
i am having a database and i entered some data and deleted it also.Now the Primary Key starts from 4 or say any thing..i want it to start it from 1.And the primary key is auto incremented and not for replication.So how to do it.Please help me out.
Mohinder Singh
|
|
|
|
|
DBCC CHECKIDENT[^]
DBCC CHECKIDENT('MyTable', RESEED, 0)
You need to be logged on as a user with at least one of the following roles: sysadmin , db_owner or db_dlladmin
|
|
|
|
|
Rename ur column[PK].
Add new column with the name of pk column.
Now delete the column u renamed.
Your problem will be solved.
Do good and have good.
|
|
|
|
|
That is the craziest solution I've heard!
|
|
|
|
|
Best Regards,
Apurva Kaushal
|
|
|
|
|
|
No, it won't! You'll just create an empty column. The key ID's won't be regenerated for any existing rows.
Dave Kreskowiak
Microsoft MVP - Visual Basic
|
|
|
|
|
Hi
How can i extract hour from datatime varable???
Good bye
Best Regards
N.Nikolov
when i want to read something good just seat and type it
|
|
|
|
|
This is what i know you can use this code to extract hour from datetime variable
COleDateTime oOleDateTime(DateTimeVariable);
int iDay = oOleDateTime.GetDay();
int iMonth = oOleDateTime.GetMonth();
int iYear = oOleDateTime.GetYear();
int iHour = oOleDateTime.GetHour();
int iMinute = oOleDateTime.GetMinute();
int iSeconds = oOleDateTime.GetSecond();
|
|
|
|
|
Thank's a lot
when i want to read something good just seat and type it
|
|
|
|
|
Hi
Can i get parameters from the user at run time in a SQL Procedure. I want to implement a SQL function just like i used to do in my C++ introductory classes. In the function, i want to ask user to enter name, age, class, and address etc one by one and then i would store this record using INSERT query. Can anyone plz help me?
Thank you
We Believe in Excellence
www.aqueelmirza.cjb.net
|
|
|
|