Maria Rekouts | 2 Oct 2005 13:45

FW: [ANN] Sedna v0.5

 
-----Original Message-----
From: Maria Rekouts [mailto:upa-OKwSzpWHb4msTnJN9+BGXg@public.gmane.org]
Sent: Wednesday, September 28, 2005 3:34 PM
To: Siver Andrey
Subject: RE: [Sedna-discussion] [ANN] Sedna v0.5

Hello,
 
The query you sent contains TO as a function name, that is, unfortunatly, currently is a reserved word.
We are working on this parser's problem, next release will contain the fixes;)
but now just change the name of the function.
 
Best regards,
 
Maria
-----Original Message-----
From: sedna-discussion-admin-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org [mailto:sedna-discussion-admin-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org]On Behalf Of Siver Andrey
Sent: Wednesday, September 28, 2005 1:34 PM
To: sedna-discussion-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org
Subject: Re: [Sedna-discussion] [ANN] Sedna v0.5

Hello,
 
I've installed the new version of Sedna under Linux but now some queries do not work with Apache.
 
I added "guest" user with corresponding privelleges (see log below), so the simplest queries work:
 
But this one (attached) does not:
 
 
What may be wrong?
 
 
Security log:
 
<db_security_data>
 <users>
  <user>
   <user_name>guest</user_name>
   <user_psw>guest</user_psw>
   <creator>user</creator>
   <privileges>
    <privilege>
     <pr_name>ALL</pr_name>
     <database_obj type_obj="document">voc</database_obj>
     <grantor>SYSTEM</grantor>
    </privilege>
    <privilege>
     <pr_name>ALL</pr_name>
     <database_obj type_obj="document">config</database_obj>
     <grantor>SYSTEM</grantor>
    </privilege>
    <privilege>
     <pr_name>ALL</pr_name>
     <database_obj type_obj="document">request_parameters</database_obj>
     <grantor>SYSTEM</grantor>
    </privilege>
    <privilege>
     <pr_name>ALL</pr_name>
     <database_obj type_obj="document">ihep</database_obj>
     <grantor>SYSTEM</grantor>
    </privilege>
    <privilege>
     <pr_name>OWNER</pr_name>
     <database_obj type_obj="document">users</database_obj>
     <grantor>guest</grantor>
    </privilege>
    <privilege>
     <pr_name>OWNER</pr_name>
     <database_obj type_obj="document">feedback</database_obj>
     <grantor>guest</grantor>
    </privilege>
    <privilege>
     <pr_name>OWNER</pr_name>
     <database_obj type_obj="document">config</database_obj>
     <grantor>guest</grantor>
    </privilege>
    <privilege>
     <pr_name>OWNER</pr_name>
     <database_obj type_obj="document">user-comments</database_obj>
     <grantor>guest</grantor>
    </privilege>
    <privilege>
     <pr_name>ALL</pr_name>
     <grantor>SYSTEM</grantor>
    </privilege>
   </privileges>
   <role role_name="PUBLIC" grantor="SYSTEM"/>
  </user>
  <user>
   <user_name>SYSTEM</user_name>
   <user_psw>MANAGER</user_psw>
   <user_creator>SYSTEM</user_creator>
   <privileges>
    <privilege>
     <pr_name>OWNER</pr_name>
     <database_obj type_obj="document">DataGuide_config</database_obj>
     <grantor>SYSTEM</grantor>
    </privilege>
    <privilege>
     <pr_name>OWNER</pr_name>
     <database_obj type_obj="document">voc</database_obj>
     <grantor>SYSTEM</grantor>
    </privilege>
   </privileges>
   <role role_name="DBA" grantor="SYSTEM"/>
   <role role_name="PUBLIC" grantor="SYSTEM"/>
  </user>
 </users>
 <roles>
  <role>
   <role_name>DBA</role_name>
   <privileges/>
  </role>
  <role>
   <role_name>PUBLIC</role_name>
   <privileges/>
  </role>
 </roles>
</db_security_data>
 
 
Andrey
----- Original Message -----
Sent: Tuesday, September 27, 2005 4:41 PM
Subject: [Sedna-discussion] [ANN] Sedna v0.5

Hi,

 

we are pleased to announce a new version 0.5 of Sedna.

 

http://www.modis.ispras.ru/Development/sedna.htm

 

New:

- Support for transactions (rollback and concurrency control)

- Support for database security (users and privileges)

- Support for Unicode (utf8)

- Support for XQuery external functions implemented in C

  (limited to deal with sequences of atomic values only)

- Directory structure and file names changed according to "Filesystem

Hierarchy Standard" (http://www.pathname.com/fhs/pub/fhs-2.3.html).

- Support for the following standard XQuery functions is added:

fn:string, fn:string-length, fn:concat, fn:data

- Update language is extended with the replace statement

- Parameters of DDL statements are now computable

- No limitation on the size of an XQuery query

- Sedna API driver for the Gambit-C implementation of Scheme

- Sedna package for Alt Linux is now availible at

http://altlinux.org/index.php?module=sisyphus&package=sedna

(the package includes the previous version 0.4)

- Bug fixes

 

Cheers,

Maxim Grinev

Sedna team

Maria Rekouts | 2 Oct 2005 13:44

FW: [ANN] Sedna v0.5

 
-----Original Message-----
From: Maria Rekouts [mailto:upa-OKwSzpWHb4msTnJN9+BGXg@public.gmane.org]
Sent: Wednesday, September 28, 2005 3:44 PM
To: Siver Andrey
Subject: RE: [Sedna-discussion] [ANN] Sedna v0.5

Hi Andrey,
it seems like the user was not granted with the privilege QUERY on document "d1179020616".
 
The privilege QUERY must be explicitly granted on a newly created document and cannot be granted in advance. But if you use collections of documents - you can only grant QUERY on a collection and all the documents in this collection will be available for quering.
 
You can read about this new feature in Sedna's Admin Guide,
 
Best regards,
Maria Rekouts
-----Original Message-----
From: sedna-discussion-admin-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org [mailto:sedna-discussion-admin-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org]On Behalf Of Siver Andrey
Sent: Wednesday, September 28, 2005 1:40 PM
To: sedna-discussion-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org
Subject: Re: [Sedna-discussion] [ANN] Sedna v0.5

By the way...
 
This error message may be interesting:
 
 
Andrey
----- Original Message -----
Sent: Tuesday, September 27, 2005 4:41 PM
Subject: [Sedna-discussion] [ANN] Sedna v0.5

Hi,

 

we are pleased to announce a new version 0.5 of Sedna.

 

http://www.modis.ispras.ru/Development/sedna.htm

 

New:

- Support for transactions (rollback and concurrency control)

- Support for database security (users and privileges)

- Support for Unicode (utf8)

- Support for XQuery external functions implemented in C

  (limited to deal with sequences of atomic values only)

- Directory structure and file names changed according to "Filesystem

Hierarchy Standard" (http://www.pathname.com/fhs/pub/fhs-2.3.html).

- Support for the following standard XQuery functions is added:

fn:string, fn:string-length, fn:concat, fn:data

- Update language is extended with the replace statement

- Parameters of DDL statements are now computable

- No limitation on the size of an XQuery query

- Sedna API driver for the Gambit-C implementation of Scheme

- Sedna package for Alt Linux is now availible at

http://altlinux.org/index.php?module=sisyphus&package=sedna

(the package includes the previous version 0.4)

- Bug fixes

 

Cheers,

Maxim Grinev

Sedna team

Dmitry Lizorkin | 3 Oct 2005 12:26
Picon

Re: How to enumerate items in `for'

Hello Andrey,
 
Indeed, the `at' clause in the FLWOR-expression is not yet implemented in Sedna.
 
> let $i := 0 return
> for $a in (1,2,3)
> let $i := $i + 1
> return ($i , " = " , $a, "^^^")
> (there I expected that $i would keep position of $a)
 
The solution you suggested won't work in XQuery, since XQuery is a functional language, not an imperative one.
 
The way to handle the situation is currently to `cons'  each item with its position before binding the sequence to a variable in the for-clause. Since XQuery automatically "flattens" a sequence, a temporary element has to be constructed for storing an item and its position. The solution in XQuery thus looks as follows:
 
declare function enum_helper_iterate($s as item()*, $i as xs:integer) as node()* {
  if(fn:empty($s))
  then ()
  else
  (<dummy>
    <item>{$s[position()=1]}</item>
    <pos>{$i}</pos>
   </dummy>,
   enum_helper_iterate($s[position()>1], $i+1)
  )
};
 
declare function enum_items($s as item()*) as node()* {
 enum_helper_iterate($s, 1)
};
 
for $a in enum_items(("a","b","c"))
return
 fn:concat($a/pos, " = ", $a/item)
Produces the expected result:
1 = a
2 = b
3 = c
 
Regards,
Dmitry
Sedna team
 
----- Original Message -----
Sent: Monday, October 03, 2005 11:30 AM
Subject: [Sedna-discussion] How to enumerate items in `for'

Hello,
 
How could I enumerate items in `for' clause?

As I could see `at' clause is not yet supported.

I wonder:
1) (perhaps I do not inderstand `let' operator correctly) that this does not work:
 
let $i := 0 return
for $a in (1,2,3)
let $i := $i + 1
return ($i , " = " , $a, "^^^")
(there I expected that $i would keep position of $a)
 
2) This one gives error message:
for $a in (1,2,3)
return (position($a) , " = " , $a, "^^^")
SE5025
Variable undeclared.
Details: $i
 
Regards,
 
Andrey
Alexander Boldakov | 8 Oct 2005 12:19
Picon

Re: "XQuery parser syntax error" problem

Hello, Andrey

This problem comes from inconformity between 'se_trn' and 'mod_sedna'. 
They both have undocumented
feature of executing several XQuery expressions at once, but the 
separators are different. 'Se_trn' treats
the sequence of characters "\n \" as the separator of XQuery 
expressions  while 'mod_sedna' uses "end;".  For
this moment the way to run your query via se_trn is to rewrite it as:

CREATE DOCUMENT "user-comments"
\
DROP DOCUMENT "user-comments"

The next version of 'mod_sedna' is going to use the same separator as 
se_trn. (with support for "end;" for
compatibility with legacy applications)

Alexander Boldakov
Sedna team

>Hello, Sedna team,
>
>I have query file with >>>
>CREATE DOCUMENT "user-comments" end;
>
>DROP DOCUMENT "user-comments" end;
><<<
>and run it via `se_trn'. One says: >>>
>
>SE4001
>XQuery parser syntax error.
>Details: Not found end of file
>
><<<
>
>
>What may be wrong there?
>
>
>
>Regards,
>
>Andrey
>  
>

Maria Rekouts | 11 Oct 2005 12:51

RE: "Connection reset by peer: socket write error"

Hello Andrey,
 
This unfortunately means there was soft fault on server. it might be "continued" because of your database has been corrupted after the soft fault.
 
Please, provide us with some additional info on what were you doing if it is possible.
 
Maria Rekouts,
SednaTeam


 
 -----Original Message-----
From: sedna-discussion-admin-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org [mailto:sedna-discussion-admin-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org]On Behalf Of Siver Andrey
Sent: Tuesday, October 11, 2005 12:22 PM
To: Sedna Discussion
Subject: [Sedna-discussion] "Connection reset by peer: socket write error"

Hello, Sedna team,
 
I was using Sedna for some time with java API and suddenly met continued error:
 
"ru.ispras.sedna.driver.DriverException: Error while IO to server: java.net.SocketException: Connection reset by peer: socket write error"
 
after which Sedna crashes.
 
What does it possibly mean?
 
 
Andrey
Maria Rekouts | 12 Oct 2005 16:28

RE: ru.ispras.sedna.driver.DriverException: Query too long.

Hello Andrey,
 
It seems that your statement is about more than 10240 bytes (that is the size of a socket message of the Sedna Low Level Socket protocol). Currently, Sedna supports statements of the size more than 10240 bytes. But, unfortunately, this possibility is not yet implemented in Java API (there is such in C API). We will add it to Java API in the nearest future.
 
But however, inserting large amounts of data is preferably do by means of LOAD. Update statements that allow streaming inserting of large amounts of data are under discussion here currently, and will probably present in the future Sedna releases.
 
Maria Rekouts,
Sedna Team
 
-----Original Message-----
From: sedna-discussion-admin-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org [mailto:sedna-discussion-admin-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org]On Behalf Of Siver Andrey
Sent: Wednesday, October 12, 2005 6:05 PM
To: Sedna Discussion
Subject: [Sedna-discussion] ru.ispras.sedna.driver.DriverException: Query too long.

Hello, Sedna team,
 
How long Query can usually be in UPDATE statement?
 
As can I see, I should use loading document instead of UPDATE statement...
 
 
Regards,
 
 
-Andrey Siver
Bertucci, Eve | 13 Oct 2005 13:56
Favicon

apache server and syntax error at token : 'Eof'

Hello Sedna team,
 
I had a query that was working OK with the apache server and I have added to it the following function declaration :
 
declare function local:xsearch_matching_criteria($credit as node()*, $director as xs:string, $actor1 as xs:string, $actor2 as xs:string, $actor3 as xs:string) as xs:boolean {
   let $matching_director := if ($director eq "") then fn:false() else $credit[ <at> role="director"] = $director
   let $matching_actor1 := if ($actor1 eq "") then fn:false() else $credit[ <at> role="actor"] = $actor1
   let $matching_actor2 := if ($actor2 eq "") then fn:false() else $credit[ <at> role="actor"] = $actor2
   let $matching_actor3 := if ($actor3 eq "") then fn:false() else $credit[ <at> role="actor"] = $actor3
   return $matching_director or $matching_actor1 or $matching_actor2 or $matching_actor3
};  
 
With this new function declaration, I get the following error when I execute my query through my apache server : 
 
SE4001
XQuery parser syntax error.
Details: syntax error at token: 'Eof', line: 291
 
The line 291 is a line of the main part of the query.
When I execute the same query with se_trn in command line, everything is OK and the result is correct if I add a call to the function local:xsearch_matching_criteria.
Can you tell me what is wrong in this code ?  
Thank you very much,
Regards,
 
Eve
***********************************************************************************
Information contained in this email message is confidential and may be privileged, and is intended only for use of the individual or entity named above. If the reader of this message is not the intended recipient, or the employee or agent responsible to deliver it to the intended recipient, you are hereby notified that any dissemination, distribution or copying of this communication is strictly prohibited. If you have received this communication in error, please immediately notify the postmaster-EiaatyUXT+w@public.gmane.org and destroy the original message.
***********************************************************************************
Alexander Boldakov | 14 Oct 2005 11:17
Picon

Re: apache server and syntax error at token : 'Eof'

Hello Eve,

We've tried your function via Apache, everything seems to be ok.
What size is your query?
Can you send us the main part of the query?

Alexander Boldakov
Sedna team.

>Hello Sedna team,
> 
>I had a query that was working OK with the apache server and I have
>added to it the following function declaration :
> 
>declare function local:xsearch_matching_criteria($credit as node()*,
>$director as xs:string, $actor1 as xs:string, $actor2 as xs:string,
>$actor3 as xs:string) as xs:boolean {
>   let $matching_director := if ($director eq "") then fn:false() else
>$credit[ <at> role="director"] = $director
>   let $matching_actor1 := if ($actor1 eq "") then fn:false() else
>$credit[ <at> role="actor"] = $actor1
>   let $matching_actor2 := if ($actor2 eq "") then fn:false() else
>$credit[ <at> role="actor"] = $actor2
>   let $matching_actor3 := if ($actor3 eq "") then fn:false() else
>$credit[ <at> role="actor"] = $actor3
>   return $matching_director or $matching_actor1 or $matching_actor2 or
>$matching_actor3
>};   
> 
>With this new function declaration, I get the following error when I
>execute my query through my apache server : 
> 
>SE4001
>XQuery parser syntax error.
>Details: syntax error at token: 'Eof', line: 291
> 
>The line 291 is a line of the main part of the query.
>When I execute the same query with se_trn in command line, everything is
>OK and the result is correct if I add a call to the function
>local:xsearch_matching_criteria.
>Can you tell me what is wrong in this code ?  
>Thank you very much,
>Regards,
> 
>Eve
>***********************************************************************************
>Information contained in this email message is confidential and may be privileged, and is intended only
for use of the individual or entity named above. If the reader of this message is not the intended
recipient, or the employee or agent responsible to deliver it to the intended recipient, you are hereby
notified that any dissemination, distribution or copying of this communication is strictly
prohibited. If you have received this communication in error, please immediately notify the
postmaster@... and destroy the original message.
>*********************************************************************************** 
>
>
>  
>

Alexander Boldakov | 14 Oct 2005 16:10
Picon

Re: apache server and syntax error at token : 'Eof'

Hello Eve,

The error was due to a error in Sedna C API. Thank you for pointing out 
this bug. To pass
through this problem try to download new Senda build at:

http://modis.ispras.ru/FTPContent/sedna-0.6.4-bin-linux.sh

and new Sedna module for Apache HTTP Server at:

http://modis.ispras.ru/FTPContent/mod_sedna-1.3.tar.gz

Pls, make sure that you compile mod_sedna with new libsedna.a from above 
new Sedna build.

Alexander Boldakov
Sedna team

>Hello Alexander,
>
>You will find the file demo.xquery attached.
>Thanks for your help
>
>Eve 
>
>-----Message d'origine-----
>De : Alexander Boldakov [mailto:boldakov@...] 
>Envoyé : vendredi 14 octobre 2005 11:18
>À : Bertucci, Eve; sedna discussion
>Objet : Re: [Sedna-discussion] apache server and syntax error at token : 'Eof'
>
>Hello Eve,
>
>We've tried your function via Apache, everything seems to be ok.
>What size is your query?
>Can you send us the main part of the query?
>
>Alexander Boldakov
>Sedna team.
>
>
>  
>
>>Hello Sedna team,
>>
>>I had a query that was working OK with the apache server and I have 
>>added to it the following function declaration :
>>
>>declare function local:xsearch_matching_criteria($credit as node()*, 
>>$director as xs:string, $actor1 as xs:string, $actor2 as xs:string,
>>$actor3 as xs:string) as xs:boolean {
>>  let $matching_director := if ($director eq "") then fn:false() else 
>>$credit[ <at> role="director"] = $director
>>  let $matching_actor1 := if ($actor1 eq "") then fn:false() else 
>>$credit[ <at> role="actor"] = $actor1
>>  let $matching_actor2 := if ($actor2 eq "") then fn:false() else 
>>$credit[ <at> role="actor"] = $actor2
>>  let $matching_actor3 := if ($actor3 eq "") then fn:false() else 
>>$credit[ <at> role="actor"] = $actor3
>>  return $matching_director or $matching_actor1 or $matching_actor2 or
>>$matching_actor3
>>};   
>>
>>With this new function declaration, I get the following error when I 
>>execute my query through my apache server :
>>
>>SE4001
>>XQuery parser syntax error.
>>Details: syntax error at token: 'Eof', line: 291
>>
>>The line 291 is a line of the main part of the query.
>>When I execute the same query with se_trn in command line, everything 
>>is OK and the result is correct if I add a call to the function 
>>local:xsearch_matching_criteria.
>>Can you tell me what is wrong in this code ?  
>>Thank you very much,
>>Regards,
>>
>>Eve
>>***********************************************************************
>>************ Information contained in this email message is 
>>confidential and may be privileged, and is intended only for use of the individual or entity named above.
If the reader of this message is not the intended recipient, or the employee or agent responsible to
deliver it to the intended recipient, you are hereby notified that any dissemination, distribution or
copying of this communication is strictly prohibited. If you have received this communication in error,
please immediately notify the postmaster@... and destroy the original message.
>>***********************************************************************
>>************
>>
>>
>> 
>>
>>    
>>
>
>
>
>
>***********************************************************************************
>Information contained in this email message is confidential and may be privileged, and is intended only
for use of the individual or entity named above. If the reader of this message is not the intended
recipient, or the employee or agent responsible to deliver it to the intended recipient, you are hereby
notified that any dissemination, distribution or copying of this communication is strictly
prohibited. If you have received this communication in error, please immediately notify the
postmaster@... and destroy the original message.
>*********************************************************************************** 
>
>  
>

Bertucci, Eve | 18 Oct 2005 13:05
Favicon

XQuery translate function

Hello Sedna team,
 
I am currently using Sedna-0.6.4 and I don't manage to use the translate function to put a string in lower case :
fn:translate("tOtO","ABCDEFGHIJKLMNOPQRSTUVWXYZ", "abcdefghijklmnopqrstuvwxyz") returns "tOtO" and not "toto"
 
Thanks for your help
Regards
 
Eve
***********************************************************************************
Information contained in this email message is confidential and may be privileged, and is intended only for use of the individual or entity named above. If the reader of this message is not the intended recipient, or the employee or agent responsible to deliver it to the intended recipient, you are hereby notified that any dissemination, distribution or copying of this communication is strictly prohibited. If you have received this communication in error, please immediately notify the postmaster-EiaatyUXT+w@public.gmane.org and destroy the original message.
***********************************************************************************

Gmane