Hello Robert,

Thanks for the tip, but it's still complaining

Non-group key variable in SELECT: ?date in expression <bif:year>(?date)

I even tried with an extra couple of parenthesis, but no luck.

--
diogo patrĂ£o





On Thu, Mar 22, 2012 at 3:57 PM, Robert Vesse <[email protected]> wrote:

>  Generally speaking to be valid SPARQL syntax any expressions either in
> the project clause or in GROUP BY/ORDER BY/FILTER etc should be properly
> bracketed and aliased (for project expressions) e.g.
>
>  SELECT (<bif:year>(?date) AS ?year) (<bif:month>(?date) AS ?month)
> (count(distinct ?document) AS ?documents)
>
> {
>        ?document a :Document;
>                 :documentDateOfCreation ?date;
>                 :documentType ?docType.
>        FILTER ( ?docType = "exam results"^^xsd:string )
> }
> group by (<bif:year>(?date)) (<bif:month>(?date))
>
>  Try the above and see if that works
>
>
> Rob Vesse -- YarcData.com -- A Division of Cray Inc
> Software Engineer, Bay Area
> m: 925.960.3941  |  o: 925.264.4729 | @: [email protected]  |  Skype:
> rvesse
> 6210 Stoneridge Mall Rd  |  Suite 120  | Pleasanton CA, 94588
>
>
>
> On Mar 22, 2012, at 11:43 AM, Diogo FC Patrao wrote:
>
> SELECT <bif:year>(?date) <bif:month>(?date) count(distinct ?document)
> {
>        ?document a :Document;
>                 :documentDateOfCreation ?date;
>                 :documentType ?docType.
>        FILTER ( ?docType = "exam results"^^xsd:string )
> }
> group by <bif:year>(?date) <bif:month>(?date)
>
>
>

Reply via email to