[pgrouting-users] Σχετ: Subject: Re: [postgis-users] k-shortst paths

Stephen Woodbridge woodbri at swoodbridge.com
Wed Sep 25 10:11:34 PDT 2013


You are running pgrouting 1.x and these functions do not exist until the 
2.0 releases.

You will have to upgrade to 2.0 to use these functions. Go to the 
website, read the 2.0 release notes and documentation.

Thanks,
   -Steve

On 9/25/2013 11:31 AM, Tina Musa wrote:
> select * from pgr_version();
>
> ERROR:  function pgr_version() does not exist
> LINE 1: select * from pgr_version();
>                        ^
> HINT:  No function matches the given name and argument types. You might
> need to add explicit type casts.
>
> ********** Error **********
>
> ERROR: function pgr_version() does not exist
> SQL state: 42883
> Hint: No function matches the given name and argument types. You might
> need to add explicit type casts.
> Character: 15
>
> select version();
>
> "PostgreSQL 9.1.7, compiled by Visual C++ build 1500, 32-bit"
>
> ------------------------------------------------------------------------
> *Απο:* Stephen Woodbridge <woodbri at swoodbridge.com>
> *Προς:* Tina Musa <timuso at yahoo.gr>; pgRouting Users List
> <pgrouting-users at lists.osgeo.org>
> *Στάλθηκε:* 5:27 μ.μ. Τετάρτη, 25 Σεπτεμβρίου 2013
> *Θέμα:* Re: Subject: Re: [postgis-users] k-shortst paths
>
> Please post this on the pgrouting list so others can learn from your
> experience.
>
> What do the follow queries report?
> select * from pgr_version();
> select version();
>
> Try changing the query to:
>
> select ksp.id1, ksp.id3, n.source, n.target,
>    round(st_length(n.the_geom)::numeric, 2) as len
>      from pgr_ksp(
>        'select source, target, cost,reverse_cost, id from network order
> by id'::text,
>        4,
>        5,
> 15,
>        'f'::boolean) ksp,
>            network n
>      where ksp.id3=n.id
>      order by ksp.id1, ksp.id3;
>
> By the way this function is part of pgRouting 2.0 and will not work on
> version 1.x
>
> -Steve
>
> On 9/25/2013 8:54 AM, Tina Musa wrote:
>  > Hello Steve,
>  >
>  > thank you for the help
>  >
>  > I loaded data file, it is ok.
>  > I saw the test file, i run the sql query
>  >
>  >
>  > -- Generate 15 shortest paths between nodes 4 and 5
>  > --
>  > -- List by links
>  > --
>  > select ksp.id1, ksp.id3, n.source, n.target,
>  > round(st_length(n.the_geom)::numeric, 2) as len
>  >    from pgr_ksp(
>  >      'select source, target, cost,reverse_cost, id from network order by
>  > id',
>  >      4,
>  >      5,
>  > 15,
>  >      'f') ksp,
>  >          network n
>  >  where ksp.id3=n.id
>  >  order by ksp.id1, ksp.id3;
>  >
>  > But it the function pgr_ksp doesn't existed
>  > Who can be the problem?
>  >
>  >
>  > ERROR: function pgr_ksp(unknown, integer, integer, integer, unknown)
>  > does not exist LINE 2: from pgr_ksp( ^ HINT: No function matches the
>  > given name and argument types. You might need to add explicit type
>  > casts. ********** Error ********** ERROR: function pgr_ksp(unknown,
>  > integer, integer, integer, unknown) does not exist SQL state: 42883
>  > Hint: No function matches the given name and argument types. You might
>  > need to add explicit type casts. Character: 77
>  >
>  >
>  >
>  >
>  >
>  >
>  > Message: 10
>  > Date: Mon, 23 Sep 2013 09:25:49 -0400
>  > From: Stephen Woodbridge <woodbri at swoodbridge.com
> <mailto:woodbri at swoodbridge.com>
>  > <mailto:woodbri at swoodbridge.com <mailto:woodbri at swoodbridge.com>>>
>  > To: postgis-users at lists.osgeo.org
> <mailto:postgis-users at lists.osgeo.org>
> <mailto:postgis-users at lists.osgeo.org
> <mailto:postgis-users at lists.osgeo.org>>
>  > Subject: Re: [postgis-users] k-shortst paths
>  > Message-ID: <5240415D.2080608 at swoodbridge.com
> <mailto:5240415D.2080608 at swoodbridge.com>
>  > <mailto:5240415D.2080608 at swoodbridge.com
> <mailto:5240415D.2080608 at swoodbridge.com>>>
>  > Content-Type: text/plain; charset=ISO-8859-1; format=flowed
>  >
>  > Tina,
>  >
>  > you should be asking this question on the Pgrouting-users mailing list
>  > Pgrouting-users at lists.osgeo.org
> <mailto:Pgrouting-users at lists.osgeo.org>
> <mailto:Pgrouting-users at lists.osgeo.org
> <mailto:Pgrouting-users at lists.osgeo.org>>
>  > http://lists.osgeo.org/mailman/listinfo/pgrouting-users
>  >
>  > If you look in github
>  > https://github.com/pgRouting/pgrouting/tree/master/src/ksp/test
>  > there are tests for all the code, load the *.data file, then look at the
>  > *.test files and you can run them.
>  >
>  > Docs are here
>  > http://docs.pgrouting.org/
>  >
>  > See you on the other list.
>  >
>  > -Steve
>  >
>  >
>  > On 9/23/2013 8:57 AM, Tina Musa wrote:
>  >> Hello,
>  >>
>  >> I see in pg routing web site that provide Yen algorithm function.
>  >> I try to run the algorithm but it's impossible to do.
>  >> Can you tell me the steps that i can do to run the algorithm
> successfully?
>  >>
>  >> Thank you in advance
>
>
>



More information about the Pgrouting-users mailing list