[postgis-users] St_LineToCurve error, geometry requires more points

Davide Ticozzi davide at geosar.ch
Tue Nov 17 08:37:36 PST 2009


Hi everyone,

I'm encured in a very strange issue.


This select give me an "geometry requires more points" error for a
specific geometry:
select st_linetocurve(the_geom) from covers where id_cover=2787;

but not this:
select st_linetocurve(geomfromtext(astext(the_geom))) from covers where
id_cover=2787;

Why?



Here there is the geometry that encors into this error:

LINESTRING(723433.642287571 120390.270478127,723433.648399855
120390.248369814,723433.660009611 120390.209061386,723433.672303626
120390.169961564,723433.685278155 120390.131082257,723433.698929245
120390.092435308,723433.713252738 120390.05403249,723433.728244271
120390.0158855,723433.743899278 120389.978005959,723433.760212989
120389.940405404,723433.777180436 120389.903095289,723433.79
120389.876,723433.79479645 120389.86608698,723433.813055665
120389.829391749,723433.831952519 120389.793020774,723433.851481256
120389.756985135,723433.871635928 120389.721295807,723433.892410394
120389.685963662,723433.913798327 120389.650999463,723433.935793213
120389.61641386,723433.95838835 120389.582217389,723433.981576857
120389.548420465,723434.005351669 120389.515033384,723434.029705546
120389.482066315,723434.054631068 120389.449529301,723434.080120643
120389.417432254,723434.106166506 120389.385784949,723434.132760724
120389.354597027,723434.159895196 120389.323877988,723434.187561657
120389.29363719,723434.215751678 120389.263883844,723434.244456674
120389.234627014,723434.273667899 120389.20587561,723434.303376457
120389.177638392,723434.333573297 120389.14992396,723434.364249222
120389.122740757,723434.395394887 120389.096097062,723434.427
120389.07,723434.45575343 120389.047106177,723434.488196686
120389.022141119,723434.521070701 120388.997746076,723434.554365462
120388.973928479,723434.588070826 120388.950695583,723434.622176526
120388.928054466,723434.656672174 120388.906012024,723434.691547262
120388.88457497,723434.726791166 120388.863749836,723434.762393151
120388.843542965,723434.798342373 120388.823960512,723434.834627879
120388.805008441,723434.871238619 120388.786692527,723434.90816344
120388.769018347,723434.945391093 120388.751991286,723434.98291024
120388.735616531,723435.020709452 120388.719899069,723435.058777214
120388.704843689,723435.097101931 120388.690454975,723435.135671928
120388.676737311,723435.174475457 120388.663694876,723435.213500698
120388.651331642,723435.252735764 120388.639651376,723435.255
120388.639,723435.292168702 120388.628657635,723435.331787502
120388.618353767,723435.371580095 120388.608742913,723435.411534361
120388.599827999,723435.451638127 120388.591611741,723435.491879179
120388.584096641,723435.532245259 120388.577284989,723435.572724071
120388.57117886,723435.613303283 120388.565780114,723435.653970537
120388.561090394,723435.694713444 120388.557111131,723435.735519593
120388.553843535,723435.776376555 120388.551288602,723435.817271883
120388.549447111,723435.858193122 120388.548319622,723435.899127805
120388.547906479,723435.940063465 120388.548207808,723435.98098763
120388.549223517,723436.021887836 120388.550953296,723436.062751624
120388.553396618,723436.103566547 120388.55655274,723436.144320171
120388.5604207,723436.185 120388.565,723440.739120394.008,723499.024
120400.047,723498.607 120403.984,723498.601671439
120404.044419126,723498.595265028 120404.131785807,723498.590384351
120404.219250989,723498.587030896 120404.306788029,723498.585205684
120404.394370262,723498.58490927 120404.481971011,723498.586141745
120404.569563591,723498.588902734 120404.65712132,723498.593191396
120404.744617528,723498.599006423 120404.832025562,723498.606346046
120404.919318798,723498.615208028 120405.006470644,723498.625589669
120405.093454554,723498.637487808 120405.180244031,723498.65089882
120405.266812638,723498.66581862 120405.353134006,723498.682242663
120405.439181841,723498.700165946 120405.524929931,723498.71958301
120405.610352157,723498.74048794 120405.695422498,723498.755
120405.751,723498.762874369 120405.780115041,723498.786735477
120405.864403988,723498.812063995 120405.948263663,723498.838852209
120406.031668523,723498.867091958 120406.114593161,723498.896774641
120406.197012318,723498.927891216 120406.278900887,723498.960432204
120406.360233926,723498.994387693 120406.440986658,723499.02974734
120406.521134486,723499.066500374 120406.600652997,723499.1046356
120406.679517967,723499.144141401 120406.757705375,723499.185005744
120406.835191403,723499.22721618 120406.911952448,723499.270759853
120406.987965129,723499.315623497 120407.063206291,723499.361793449
120407.137653014,723499.409255642 120407.211282622,723499.457995621
120407.284072687,723499.508 120407.356,723499.54118933
120407.402357935,723499.593275444 120407.472940908,723499.646585467
120407.542604103,723499.701103161 120407.6113263,723499.756811919
120407.679086565,723499.813694772 120407.745864258,723499.871734394
120407.811639038,723499.930913103 120407.876390869,723499.991212875
120407.940100027,723500.052615341 120408.002747106,723500.115101797
120408.064313023,723500.17865321 120408.124779023,723500.243250221
120408.18412669,723500.308873153 120408.242337944,723500.375502017
120408.299395054,723500.443116516 120408.35528064,723500.511696056
120408.409977679,723500.581219746 120408.463469509,723500.651666408
120408.515739836,723500.723014583 120408.566772739,723500.795242539
120408.616552671,723500.868328274 120408.665064471,723500.918
120408.697,723500.942249525 120408.712293359,723501.016983776
120408.758224951,723501.09250826 120408.802845255,723501.168799974
120408.846140679,723501.245835678 120408.888098035,723501.323591905
120408.928704542,723501.402044971 120408.967947831,723501.481170978
120409.005815948,723501.560945824 120409.042297359,723501.641345207
120409.07738095,723501.722344639 120409.111056035,723501.803919445
120409.143312357,723501.886044778 120409.174140089,723501.968695621
120409.203529841,723502.051846797 120409.23147266,723502.135472979
120409.257960036,723502.219548692 120409.2829839,723502.304048327
120409.306536628,723502.388946144 120409.328611048,723502.474216282
120409.349200434,723502.559832767 120409.368298515,723502.645769521
120409.385899474,723502.732 120409.402,723508.51 120409.991,723552.271
120414.462,723548.595 120417.382,723550.118 120419.25,723586.318
120422.946,723591.811 120418.531,723593.582 120418.712,723605.256
120419.866,723605.356 120418.871,723606.483 120407.617,723606.500230432
120407.432995197,723606.514248199 120407.248717815,723606.525047747
120407.064223855,723606.532625786 120406.879569517,723606.536980009
120406.694811048,723606.538109089 120406.510004726,723606.536012682
120406.325206846,723606.530691426 120406.140473699,723606.522146943
120405.955861557,723606.510381835 120405.771426654,723606.495399686
120405.58722517,723606.47720506 120405.403313216,723606.455803499
120405.219746813,723606.431201521 120405.036581876,723606.403406622
120404.8538742,723606.401 120404.839,723606.372427268
120404.671679439,723606.338272894 120404.490053092,723606.300953906
120404.309050483,723606.260481671 120404.128726748,723606.216868517
120403.949136814,723606.170127728 120403.770335388,723606.120273544
120403.592376934,723606.067321148 120403.415315658,723606.011286673
120403.239205497,723605.952187186 120403.064100095,723605.890040689
120402.89005279,723605.824866113 120402.7171166,723605.756683312
120402.545344202,723605.685513052 120402.374787919,723605.611377015
120402.205499705,723605.599 120402.178,723605.520578438
120402.011024868,723605.4392548 120401.845443765,723605.35505376
120401.681307174,723605.268000966 120401.518665093,723605.178122934
120401.357567063,723605.085447043 120401.198062158,723604.990001522
120401.040198963,723604.891815446 120400.884025566,723604.790918722
120400.729589537,723604.687342085 120400.576937921,723604.581117085
120400.426117216,723604.472276079 120400.277173364,723604.360852222
120400.130151733,723604.25 120399.989,723604.246879454
120399.98509711,723604.130392492 120399.842053678,723604.01142682
120399.70106501,723603.890018675 120399.562174052,723603.76620504
120399.425423113,723603.640023629 120399.290853847,723603.511512879
120399.158507246,723603.380711935 120399.028423624,723603.24766064
120398.900642606,723603.112399524 120398.775203115,723602.974969787
120398.65214336,723602.835413293 120398.531500828,723602.693772551
120398.413312267,723602.550090707 120398.297613678,723602.413
120398.191,723602.26538871 120398.080134964,723602.115865042
120397.971862983,723601.964474541 120397.86621704,723601.811263322
120397.763229316,723601.656278053 120397.662931182,723601.499565946
120397.56535319,723601.341174736 120397.470525063,723601.181152671
120397.378475687,723601.019548494 120397.2892331,723600.856411434
120397.202824487,723600.691791181 120397.119276169,723600.525737881
120397.038613595,723600.358302117 120396.960861336,723600.189534889
120396.886043076,723600.019487607 120396.814181605,723599.85
120396.746,723599.848212068 120396.745298814,723599.675760445
120396.679415684,723599.502185268 120396.616552285,723599.32753941
120396.556727764,723599.151876069 120396.499960345,723598.975248755
120396.446267321,723598.797711269 120396.395665045,723598.619317692
120396.348168933,723598.440122364 120396.303793452,723598.260179868
120396.26255212,723598.079545019 120396.224457498,723597.898272838
120396.189521191,723597.716418543 120396.157753841,723597.534037529
120396.129165124,723597.35118535 120396.103763749,723597.167917706
120396.081557453,723596.989 120396.063,723551.636 120391.423,723489.001
120384.993,723485.177 120384.6,723485.373 120382.977,723487.086
120368.814,723487.093 120368.732,723483.049 120368.393,723436.72
120364.507,723434.32 120383.669,723436.265 120373.572,723436.272506212
120373.5386552,723436.280599035 120373.505447842,723436.289270173
120373.472386781,723436.298516986 120373.439482087,723436.308336656
120373.406743784,723436.318726193 120373.374181844,723436.329682432
120373.341806186,723436.341202035 120373.309626671,723436.353281494
120373.277653103,723436.365917128 120373.24589522,723436.37910509
120373.214362695,723436.392841362 120373.183065136,723436.407121759
120373.152012073,723436.421941932 120373.121212968,723436.437297366
120373.090677201,723436.453183384 120373.060414074,723436.469595147
120373.030432806,723436.486527656 120373.000742529,723436.503975752
120372.971352287,723436.521934122 120372.942271032,723436.540397294
120372.913507623,723436.554 120372.893,723436.559359645
120372.885070822,723436.578815398 120372.856969291,723436.598758628
120372.829211589,723436.619183259 120372.801806172,723436.64008307
120372.774761389,723436.661451694 120372.748085476,723436.683282622
120372.72178656,723436.705569205 120372.695872652,723436.728304653
120372.670351645,723436.751482042 120372.645231313,723436.775094311
120372.620519308,723436.799134267 120372.596223158,723436.823594589
120372.572350264,723436.848467824 120372.548907897,723436.873746397
120372.525903199,723436.899422608 120372.503343175,723436.925488634
120372.4812347,723436.951936536 120372.459584507,723436.978758259
120372.43839919,723437.00594563 120372.417685204,723437.03349037
120372.397448858,723437.061384088 120372.377696316,723437.074
120372.369,723437.102299613 120372.349980734,723437.130928284
120372.331460439,723437.159875818 120372.313442603,723437.189133398
120372.295932716,723437.218692112 120372.278936111,723437.248542955
120372.262457966,723437.278676835 120372.246503299,723437.309084573
120372.231076971,723437.339756907 120372.21618368,723437.370684492
120372.201827964,723437.401857909 120372.188014195,723437.433267662
120372.174746581,723437.464904182 120372.162029164,723437.496757834
120372.149865817,723437.528818913 120372.138260245,723437.561077655
120372.127215984,723437.593524233 120372.116736398,723437.626148763
120372.106824679,723437.658941307 120372.097483845,723437.691891877
120372.088716744,723437.724990436 120372.080526044,723437.7582269
120372.072914241,723437.791591147 120372.065883654,723437.796
120372.065,723437.825073013 120372.059436424,723437.8586623
120372.053574515,723437.892348775 120372.048299713,723437.926122177
120372.043613624,723437.959972219 120372.039517677,723437.99388859
120372.036013117,723438.027860958 120372.033101014,723438.061878975
120372.030782254,723438.095932278 120372.029057543,723438.130010496
120372.027927407,723438.164103247 120372.02739219,723438.198200147
120372.027452055,723438.232290808 120372.028106984,723438.266364847
120372.029356777,723438.300411885 120372.031201054,723438.33442155
120372.033639253,723438.368383483 120372.036670631,723438.402287338
120372.040294264,723438.436122789 120372.04450905,723438.469879528
120372.049313704,723438.503547273 120372.054706762,723438.537115768
120372.060686582,723438.570574789 120372.067251342,723438.579
120372.069,723437.785 120376.965,723437.625 120377.952,723483.828
120382.811,723483.555 120385.469,723442.078 120381.195,723436.563
120385.557,723435.142 120385.411,723435.122204594
120385.408119484,723435.102464309 120385.4048821,723435.082783531
120385.401300694,723435.063168254 120385.397376357,723435.043624454
120385.393110283,723435.024158083 120385.388503773,723435.004775073
120385.383558229,723434.985481326 120385.378275159,723434.96628272
120385.372656171,723434.947185102
120385.366702976,723434.928194291120385.360417389,723434.909316071
120385.353801324,723434.890556193 120385.346856797,723434.87192037
120385.339585922,723434.85341428 120385.331990914,723434.83504356
120385.324074087,723434.816813805 120385.315837853,723434.798730569
120385.30728472,723434.78079936 120385.298417294,723434.76302564
120385.289238276,723434.745414823 120385.279750461,723434.727972273
120385.269956741,723434.716 120385.263,723434.710703304
120385.259860097,723434.693613175 120385.249463607,723434.676707094
120385.238770436,723434.659990208 120385.227783841,723434.643467612
120385.21650717,723434.627144337 120385.204943858,723434.611025355
120385.193097426,723434.595115578 120385.180971483,723434.57941985
120385.168569724,723434.563942953 120385.155895925,723434.548689602
120385.142953947,723434.533664443 120385.129747733,723434.518872053
120385.116281305,723434.504316936 120385.102558765,723434.490003529
120385.088584293,723434.475936189 120385.074362146,723434.462119202
120385.059896657,723434.448556778 120385.04519223,723434.435253046
120385.030253347,723434.422212061 120385.015084557,723434.409437793
120384.99969048,723434.396934135 120384.984075806,723434.384704895
120384.968245292,723434.38 120384.962,723433.642287571 120390.270478127)








More information about the postgis-users mailing list