]> git.ipfire.org Git - thirdparty/sqlite.git/commitdiff
Have the xUpdate() method of the rtree module virtual table implementation set the...
authordan <dan@noemail.net>
Fri, 19 Mar 2010 19:02:27 +0000 (19:02 +0000)
committerdan <dan@noemail.net>
Fri, 19 Mar 2010 19:02:27 +0000 (19:02 +0000)
FossilOrigin-Name: f31d22489d44701c89cb13c663dfa1a6cc04f900

ext/rtree/rtree.c
ext/rtree/rtree1.test
manifest
manifest.uuid

index 3111cc2e9618871b553437bec3239793c5e93da5..6576db1412a73cb6ac79a356a4d05779726ea8b7 100644 (file)
@@ -2483,6 +2483,7 @@ static int rtreeUpdate(
       }
       rc = sqlite3_reset(pRtree->pReadRowid);
     }
+    *pRowid = cell.iRowid;
 
     if( rc==SQLITE_OK ){
       rc = ChooseLeaf(pRtree, &cell, 0, &pLeaf);
index 9d9a2b6f5504c76c8d43232c75fb28e9996f53ed..f27cb7580196715403378a97b2da81a2510a2d72 100644 (file)
@@ -399,4 +399,21 @@ do_test rtree-10.1 {
   catchsql { CREATE VIRTUAL TABLE t7 USING rtree(index, x1, y1, x2, y2) }
 } {1 {near "index": syntax error}}
 
+#-------------------------------------------------------------------------
+# Test last_insert_rowid().
+# 
+do_test rtree-11.1 {
+  execsql {
+    CREATE VIRTUAL TABLE t8 USING rtree(idx, x1, x2, y1, y2);
+    INSERT INTO t8 VALUES(1, 1.0, 1.0, 2.0, 2.0);
+    SELECT last_insert_rowid();
+  }
+} {1}
+do_test rtree-11.2 {
+  execsql {
+    INSERT INTO t8 VALUES(NULL, 1.0, 1.0, 2.0, 2.0);
+    SELECT last_insert_rowid();
+  }
+} {2}
+
 finish_test
index cd4c373e20cb2bdd4db7a07384d2daa7a1bb0a70..9993a5bdea0e0934f4f5722fa605f996330d1dfe 100644 (file)
--- a/manifest
+++ b/manifest
@@ -1,8 +1,5 @@
------BEGIN PGP SIGNED MESSAGE-----
-Hash: SHA1
-
-C Store\sthe\sSQLite\sversion\snumber\sof\sthe\slast\swriter\sin\sbits\s96..99\sof\sthe\sheader.
-D 2010-03-19T16:55:47
+C Have\sthe\sxUpdate()\smethod\sof\sthe\srtree\smodule\svirtual\stable\simplementation\sset\sthe\s*pRowid\soutput\svariable\swhen\sinserting\sa\srow.\sFix\sfor\s[dd3ba6063a].
+D 2010-03-19T19:02:28
 F Makefile.arm-wince-mingw32ce-gcc fcd5e9cd67fe88836360bb4f9ef4cb7f8e2fb5a0
 F Makefile.in 4f2f967b7e58a35bb74fb7ec8ae90e0f4ca7868b
 F Makefile.linux-gcc d53183f4aa6a9192d249731c90dbdffbd2c68654
@@ -77,9 +74,9 @@ F ext/icu/README.txt 3b130aa66e7a681136f6add198b076a2f90d1e33
 F ext/icu/icu.c 850e9a36567bbcce6bd85a4b68243cad8e3c2de2
 F ext/icu/sqliteicu.h 728867a802baa5a96de7495e9689a8e01715ef37
 F ext/rtree/README 6315c0d73ebf0ec40dedb5aa0e942bc8b54e3761
-F ext/rtree/rtree.c a354f6be11a91706680936fdf77b4588f0b34dbe
+F ext/rtree/rtree.c c7a18311f2d6ae9a42838e9c04b9e670483b4feb
 F ext/rtree/rtree.h 834dbcb82dc85b2481cde6a07cdadfddc99e9b9e
-F ext/rtree/rtree1.test f72885ed80a329d6bd7991043016d74b51edf2c5
+F ext/rtree/rtree1.test 51bb0cd0405970501e63258401ae5ad235a4f468
 F ext/rtree/rtree2.test 7b665c44d25e51b3098068d983a39902b2e2d7a1
 F ext/rtree/rtree3.test dece988c363368af8c11862995c762071894918f
 F ext/rtree/rtree4.test 94fdd570ab5bc47244d87d4590023be43ac786bd
@@ -796,14 +793,7 @@ F tool/speedtest2.tcl ee2149167303ba8e95af97873c575c3e0fab58ff
 F tool/speedtest8.c 2902c46588c40b55661e471d7a86e4dd71a18224
 F tool/speedtest8inst1.c 293327bc76823f473684d589a8160bde1f52c14e
 F tool/vdbe-compress.tcl d70ea6d8a19e3571d7ab8c9b75cba86d1173ff0f
-P 69d749d93d6565b848ce5c07f2738d144c6564bf
-R 599d0632b9cdb2c58e5d9edce25d110a
-U drh
-Z b45d6db2a12b641f2472736f902b373b
------BEGIN PGP SIGNATURE-----
-Version: GnuPG v1.4.6 (GNU/Linux)
-
-iD8DBQFLo6yWoxKgR168RlERAgeAAJ9pNOa8SRBbkNmjYgQViyfUUe2ovwCfbSGN
-06ig9VCoZq+gIHyU4IdUywc=
-=gUGm
------END PGP SIGNATURE-----
+P 146d4f5d3459235d8b2d27a5d77beb7645f75185
+R cecb3de7429c8aa39856297db7e7e065
+U dan
+Z dde395691a3822eb04a7749756af2e51
index 8788ae10345141d760e6a82c179267c1376c838e..c3a16090ac6a6d0f155aef595c0242fd437df9a3 100644 (file)
@@ -1 +1 @@
-146d4f5d3459235d8b2d27a5d77beb7645f75185
\ No newline at end of file
+f31d22489d44701c89cb13c663dfa1a6cc04f900
\ No newline at end of file