different results in queries [message #624] |
Mon, 12 February 2007 19:44 ![Go to next message Go to previous message](/theme/default/images/down.png) |
stephenboey
Messages: 54 Registered: January 2007
|
Member |
|
|
Was trying to call mysql_query, mysql_fetch_array in _cm_post_updateRecord
Can this be done? Seems like calling those does not give me any results or error messages.
I went back to mysql functions because radicore does not give me the correct results. Attached is a script to implement Van Tulder's Tree http://www.sitepoint.com/print/hierarchical-data-database.
One version is using radicore and the other using his script.
Test data:
role_id role_id_snr lft rgt
GLOBAL NULL 1 10
TESTING GLOBAL 2 9
TESTING2 TESTING 3 8
TESTING3 TESTING2 4 7
TESTING4 TESTING3 5 6
Test Scenerio (Reparent TESTING2 to GLOBAL)
role_id role_id_snr lft rgt
GLOBAL NULL 1 10
TESTING GLOBAL 2 3
TESTING2 TESTING 4 9
TESTING3 TESTING2 5 8
TESTING4 TESTING3 6 7
-
Attachment: Script.txt
(Size: 2.07KB, Downloaded 840 times)
[Updated on: Mon, 12 February 2007 20:24] Report message to a moderator
|
|
|