|
Kornfeld Eliyahu Peter wrote: Why not using order by and top? Just a guess; "it's too slow"
Bastard Programmer from Hell
If you can't read my code, try converting it here[^]
|
|
|
|
|
And nested select not? It's performance depends only on the proper indexing...
I'm not questioning your powers of observation; I'm merely remarking upon the paradox of asking a masked man who he is. (V)
|
|
|
|
|
Kornfeld Eliyahu Peter wrote: And nested select not? I did not say that
Kornfeld Eliyahu Peter wrote: It's performance depends only on the proper indexing... ..and the amount of records, the amount of fields in a row, their size, and the speed of the harddisk.
Ya reckon there's an index on the date?
Bastard Programmer from Hell
If you can't read my code, try converting it here[^]
|
|
|
|
|
Eddy Vluggen wrote: and the amount of records, the amount of fields in a row, their size
Not quiet right... With indexed table there will be two page reads only (and if the index clustered only one), not matter what size the table is...
Eddy Vluggen wrote: Ya reckon there's an index on the date
I do not think there is a table at all - it sound me like a school exercise...
I'm not questioning your powers of observation; I'm merely remarking upon the paradox of asking a masked man who he is. (V)
|
|
|
|
|
Damn you Eddy you made try to learn something today!
Every day, thousands of innocent plants are killed by vegetarians.
Help end the violence EAT BACON
|
|
|
|
|
Maybe it's just not for an SQLserver. If you want a generic query TOP is out of the question.
|
|
|
|
|
Create a table called "Cheater", containing both PatientId and last updatetime. Set both from a trigger on the Patient-table - do an insert of it doesn't contain the patient-Id, otherwise simply update the time.
Index the table on time, id.
You now have an indexed int/date table for your lookup.
Bastard Programmer from Hell
If you can't read my code, try converting it here[^]
|
|
|
|
|
Hi,
I am a user of MySql. In Mysql we can go for the query
select * from Patient where time=(select max(time) from Patient);
Hope it will work for you. Check n update.
|
|
|
|
|
Hello,
i have two user schemas.
Let's Say A & B.
A has a procedure written in it SAY 'XProc'.
B has a package which has Procedure say 'B_Pack_Proc', which creates a dynamic view in B user schema.
The B_pack_proc creates view in B schema itself.
but i am executing the B_Pack_Pro from A, i am getting error insufficient privileges.
I am using oracle forms 11g and oracle DB 11g.
i have granted explicit grants to User A from User B
i.e Create any view
Execute on view.
please help.
-
Prathamesh
|
|
|
|
|
Have you given user A privileges to execute the package?
GRANT EXECUTE ON B.packagename TO A;
|
|
|
|
|
i have explicitly granted permission on the view, package and the tables in the views.
still not working
-
Prathamesh
|
|
|
|
|
What's the exact error message?
|
|
|
|
|
I created a table in ms access, and then i wanted to connect it to a java gui front end using type 1 driver. so i tried to create an odbc dsn for access. the test for connection failed while creating the dsn itself. Any suggestions will be extremely helpful, thanks.
|
|
|
|
|
Aravinth Spirited wrote: the test for connection failed while creating the dsn itself. Any suggestions will be extremely helpful, thanks. Did the test fail silently, or was there an error-message?
I suggest you add that message to your question.
Bastard Programmer from Hell
If you can't read my code, try converting it here[^]
|
|
|
|
|
Please don't cross-post across forums - Quick Answers MS ACCESS ODBC problem[^] - it won't get your question answered any quicker!
|
|
|
|
|
Use a DSN-less connection like OLEDB. It is much faster than ODBC anyway.
"Go forth into the source" - Neal Morse
|
|
|
|
|
When there is case for writing a many number of mysql command line in VB.NET programming to how to write the module or dll file to handle easily all the command .Please suggest other weblinks or code project article in this discussion. If there is any further idea also add to this discussion.
Online Mysql with VB.Net 
|
|
|
|
|
Sounds like you are trying to build a Data Access Layer (DAL), there are many articles and examples on this subject.
Never underestimate the power of human stupidity
RAH
|
|
|
|
|
Thanks for your replay can you please suggest me the better links to refer that will help me to create my own DLL file .
|
|
|
|
|
Hi,
am developing application in .net,c#.
am saving datetime value as: yyyy-MM-ss HH:mm:ss (24 hour format)
after saving in database i observed in database , it's stored in specified format .
and here the problem is:
when i retrieve data , datetime is coming as 12 hour format.
what to do........
|
|
|
|
|
When you store date/time AS date/time in database you store some binary (like milliseconds since 1st of January 1970). Database do nothing and care less about the representation of that date/time. You have to look into the code to see where the problem (you may have locals with 12 hours).
If you store date/time as string - you do a big mistake!!!
I'm not questioning your powers of observation; I'm merely remarking upon the paradox of asking a masked man who he is. (V)
|
|
|
|
|
it's ok, but how to add milliseconds.
actually, in c# am using DateTimePicker control.this will give only (year-month-date hour:minutes:seconds)
it doesn't support milliseconds.
so , Is there any way to get the data stored in database as it is.(24 hour format)
|
|
|
|
|
You didn't read or didn't understand what I've told - database do not store date/time in any format but binary!!!
For proper formatting in your DateTimePicker go to the help of that specific control...
I'm not questioning your powers of observation; I'm merely remarking upon the paradox of asking a masked man who he is. (V)
|
|
|
|
|
You store DateTimePicker.Value, not DateTimePicker.Value.ToString() or DateTimePicker.Text. Also make sure that you set the display format of the DateTimePicker to the format you want to see.
|
|
|
|
|
Member 10263519 wrote: am saving datetime value as: yyyy-MM-ss HH:mm:ss (24 hour format)
That statement is FALSE unless you are storing the value in the database as TEXT.
Because it is false your conclusions of what happens after that is incorrect.
|
|
|
|