Without knowing your setup, its difficult to say. You may have 100 fields in each record? In a network environment try to minimise the amount of network traffic. So, you should try to refine your select statement by returning only what you need e.g. instead of >Select * from table where field_value = 1. try: select field_value,field_value1,field_value2,field_value100 from table where field_value = 1 (and field_value2=2) order by field_value,field_value2 (aim for more selective index - 2 fields, not just 1) then even better: What do you want to do with the returned data? View it? Can you handle more than 20 records at a time on your screen? select first 20 field_value,field_value1,field_value2,field_value100 from table where field_value = 1 (and field_value2=2) order by field_value,field_value2
Good luck Alan Alan J Davies Aldis On 04/03/2013 06:18, trskopo wrote: > Hi all, > > I have a table with about 5,000,000 records and it's growing. > > I run slq statement like this : > > Select * from table where field_value = 1. > > Table already indexed on field_value (int type). > > On local hardisk, where there is only 1 user and no update/edit/insert > operation, it took about 1-2 seconds to get the result, but on Local > Area Network, where there about 20 users attached to that database, lots > of update/edit/insert operation on this table,it took almost 20 seconds. > > Is there any tips / methods to improve performance? > > Thanks and regards, > Anto. > > ------------------------------------ ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Visit http://www.firebirdsql.org and click the Resources item on the main (top) menu. Try Knowledgebase and FAQ links ! Also search the knowledgebases at http://www.ibphoenix.com ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Yahoo! Groups Links <*> To visit your group on the web, go to: http://groups.yahoo.com/group/firebird-support/ <*> Your email settings: Individual Email | Traditional <*> To change settings online go to: http://groups.yahoo.com/group/firebird-support/join (Yahoo! ID required) <*> To change settings via email: firebird-support-dig...@yahoogroups.com firebird-support-fullfeatu...@yahoogroups.com <*> To unsubscribe from this group, send an email to: firebird-support-unsubscr...@yahoogroups.com <*> Your use of Yahoo! Groups is subject to: http://docs.yahoo.com/info/terms/