Login ProductsSalesSupportDownloadsAbout |
Home » Technical Support » ElevateDB Technical Support » Support Forums » ElevateDB General » View Thread |
Messages 1 to 4 of 4 total |
Performance index on temporary table |
Wed, Jul 23 2008 10:27 AM | Permanent Link |
Ries van der Velden | Hello,
I've got a client-server situation, in which I want to create a temporary table. I have two questions: - The temporary table should be created on the client machine. Can I use the TempTablesPath of the remote Session, or do I have to create a local session? - The creation of the table itself is 0 ms [fast enough]. The creation of the indexes take about 400 ms each. Is there a way to improve that? The sql: create temporary table "Test1" ("StringField" VARCHAR(20) collate "ANSI_CI", "SmallIntField" SMALLINT, "IntegerField" INTEGER, "BooleanField" BOOLEAN, "FloatField" FLOAT (16), "DateField" DATE, "TimeField" TIME, "BlobField" BLOB, "MemoField" CLOB, "GraphicField" BLOB ) create index "idxDate_Time" on "Test1" ( DateField asc, TimeField desc ) create index "idxInteger" on "Test1" ( IntegerField asc ) Thanks in advance, Regards, Ries van der Velden |
Wed, Jul 23 2008 11:41 AM | Permanent Link |
Roy Lambert NLH Associates Team Elevate | Ries
If the table isn't going to be to big, and doesn't need to persist between runs of the app, create an in memory database and create the table in there. It automatically cleans itself up when the app closes if you don't clean it up yourself. Roy Lambert [Team Elevate] |
Wed, Jul 23 2008 1:52 PM | Permanent Link |
Tim Young [Elevate Software] Elevate Software, Inc. timyoung@elevatesoft.com | Ries,
<< - The temporary table should be created on the client machine. Can I use the TempTablesPath of the remote Session, or do I have to create a local session? >> You have to use a local session. << - The creation of the table itself is 0 ms [fast enough]. The creation of the indexes take about 400 ms each. Is there a way to improve that? >> The issue is the creation of any metadata updates the database catalog, and any updates to the database catalog involve a hard flush to disk to ensure that the updates are stable on disk and don't encounter any corruption. One of the things we've got on the list for 2.x (probably 2.03), is the ability to do DDL transactions that wrap more than one DDL operation into one update to the database catalog. If you can do so, using an in-memory database like Roy suggested would get around the hard flush to disk. -- Tim Young Elevate Software www.elevatesoft.com |
Thu, Jul 24 2008 2:43 AM | Permanent Link |
Ries van der Velden | >"Tim Young [Elevate Software]" <timyoung@elevatesoft.com> wrote:
>You have to use a local session. >If you can do so, using an in-memory database like Roy suggested would get >around the hard flush to disk. Tim, Roy, Thanks for the advice. The creation and insertion in the in memory tables are indeed much faster. Regards, Ries |
This web page was last updated on Tuesday, April 30, 2024 at 03:55 PM | Privacy PolicySite Map © 2024 Elevate Software, Inc. All Rights Reserved Questions or comments ? E-mail us at info@elevatesoft.com |