Hi, how can I publish a REST web service through a Stored Procedure? I read the 
Virtuoso Server Pages (VSP), but it wasn't clear to me.

I create the following procedure:

create procedure
"WS"."WS"."/i4m/electricity/average_consumption_by_month.vsp" (IN meterID 
VARCHAR, IN month_num tinyint, IN year_num SMALLINT)
returns ANY
{
     RETURN  (SELECT AVG(quantidade)
          FROM DB.DBA.Electricity_Invoices_Data
          WHERE (
                contadorID =  meterID AND
                type = 2 AND
                month(observationTime) = month_num AND
                year(observationTime) = year_num)
                );
}



http://openiot.izone.pt:8890/i4m/electricity/average_consumption_by_month.vsp?meterID=1341384&month_num=11&year_num=2013

The requested active content cannot be displayed due to execution restriction

------------------------------------------------------------------------------
Learn Graph Databases - Download FREE O'Reilly Book
"Graph Databases" is the definitive new guide to graph databases and their
applications. Written by three acclaimed leaders in the field,
this first edition is now available. Download your free book today!
http://p.sf.net/sfu/NeoTech
_______________________________________________
Virtuoso-users mailing list
Virtuoso-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/virtuoso-users

Reply via email to