X-Query takes 30-40 seconds. Please Help!!!

I am new to tamino.

I am trying to run some simple queries, and it takes 30-40 sec to return the results. Tamino is running on a server class machine, dual 3.0Ghz, 36 gig mirror HD, and 2.0 gig of ram.

I am using the XQuery tool to run the queries. I am including the schema and the queries. We have about 20,000 records in the database. Is it possible to index the child nodes I am querying for, if it is then how do you do that? I have seen on the forums people saying the queries take 1-2 sec. It makes me think I have something major wrong with the query, schema or database setup.

Thanks!!!

Here are the queries
Query 1:

for $i in input()/PortalLog
where $i/uid=‘siqbal1’
return $i

Query 2:

declare namespace tf=“http://namespaces.softwareag.com/tamino/TaminoFunction

{
count(
for $i in input()/PortalLog
where $i/fvAuxPortalRole=‘Provider’
return $i
)
}



Query 3:

declare namespace tf=“http://namespaces.softwareag.com/tamino/TaminoFunction

{
count(
for $i in input()/PortalLog
where tf:containsText($i/Login,‘Fri Apr 02’)
return $i
)
}



[This message was edited by Shahid on 06 April 2004 at 17:55.]
PortalLogProd.TSD (6.08 KB)

Hi Sharid,
I believe that you could define a standard index for “PortalLog/uid” (Query 1) and a Text index for “PortalLog/Login” (Query 3).
I’m not sure if you have to use a index for “PortalLog/fvAuxPortalRole” (Query 2) element. How many distinct values do you have?

In order to define the indexes use the Tamino Schema Editor, select the element and modify the options in “Physical Properties” pane.

Also, check your indexes with:

?_admin=ino:DisplayIndex(CollectionName,ElementPath,StartValue, Size, IndexType (text/standard) )

and check if you could use xs:dateTime instead of xs:string datatype for “PortalLog/Login” element.

Regards,
Guille

Hi Sharid,
I believe that you could define a standard index for “PortalLog/uid” (Query 1) and a Text index for “PortalLog/Login” (Query 3).
I’m not sure if you have to use a index for “PortalLog/fvAuxPortalRole” (Query 2) element. How many distinct values do you have?

In order to define the indexes use the Tamino Schema Editor, select the element and modify the options in “Physical Properties” pane.

Also, check your indexes with:

?_admin=ino:DisplayIndex(CollectionName,ElementPath,StartValue, Size, IndexType (text/standard) )


Regards,
Guille

Hi Guille,

I am trying to do, what you suggested through the schema editor, but when I try to update the schema I get an error in the schema editor. Interesting thing is that the element it is complaining about, I have not even changed anything about that element. Only thing I did was change the uid to standard index.

Here is the error.



An error occurred while processing a schema document; Modifying an existing node definition with the specified attributes is not supported: Element name = PcConfig, parameter multiplicity not updatable <INOXDE7931,INOXRE8889>

Hi Sharid,
Here, I could change your schema but I don’t have data. Please, modify your schema and try to save it in other collection.

Regards,
Guillermo

It worked after installing the service pack 4 on tamino