[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Phpgroupware-tracker] [bug #5245] Upgrade of existing DB fails
From: |
nobody |
Subject: |
[Phpgroupware-tracker] [bug #5245] Upgrade of existing DB fails |
Date: |
Thu, 18 Sep 2003 02:39:54 -0400 |
User-agent: |
Mozilla/5.0 (X11; U; Linux i686) Gecko/20030311 Galeon/1.3.3 |
=================== BUG #5245: LATEST MODIFICATIONS ==================
http://savannah.gnu.org/bugs/?func=detailbug&bug_id=5245&group_id=509
Changes by: Jonathan Rivera <address@hidden>
Date: Thu 09/18/2003 at 06:39 (GMT)
------------------ Additional Follow-up Comments ----------------------------
hey!! i think i found where is the error, in setup scripts, in
tables_update.inc.php when try to upgrade the addresses this code run:
$db1->query("INSERT INTO phpgw_contact_addr(contact_id,add1,
city, state, postal_code, country, tz, addr_type_id,
created_on, created_by, modified_on, modified_by) VALUES ("
. $GLOBALS['phpgw_setup']->oProc->f('org_id')
. ", '" .
$db1->db_addslashes($GLOBALS['phpgw_setup']->oProc->f('adr_one_street'))
." '" . ", '" .
$db1->db_addslashes($GLOBALS['phpgw_setup']->oProc->f('adr_one_locality'))
. "'" . ", '" .
$db1->db_addslashes($GLOBALS['phpgw_setup']->oProc->f('adr_one_region'))
." '" . ", '".
$db1->db_addslashes($GLOBALS['phpgw_setup']->oProc->f('adr_one_postalcode'))
." '". ", '" .
$db1->db_addslashes($GLOBALS['phpgw_setup']->oProc->f('adr_one_countryname'))
." '". ", " .
intval($GLOBALS['phpgw_setup']->oProc->f('tz'))
. ", " .
($GLOBALS['phpgw_setup']->oProc->f('addr_type_id'))?
$GLOBALS['phpgw_setup']->oProc->f('addr_type_id') : $addr_type
. ", " . $GLOBALS['phpgw_setup']->oProc->f('created_on')
. ", " . $GLOBALS['phpgw_setup']->oProc->f('created_by')
. ", " . $GLOBALS['phpgw_setup']->oProc->f('modified_on')
. ", " . $GLOBALS['phpgw_setup']->oProc->f('modified_by')
. ");");
and for any reason the sql which this want to run is '3' i think this 3 is the
addr_type_id, but i don't know why this concatenation only returns '3'.
i will review this later and try to fix, but probably bjohnson can help me in
this :P
=================== BUG #5245: FULL BUG SNAPSHOT ===================
Submitted by: stl Project: phpGroupWare
Submitted on: Fri 09/12/2003 at 20:47
Category: API - phpGWapi Bug Group: 0.9.16RC1
Severity: 5 - Major Priority: High
Resolution: None Assigned to: alexbsa
Status: Open Component Version: CVS
Platform Version: Linux - SuSE Reproducibility: Every Time
Summary: Upgrade of existing DB fails
Original Submission: Unfortunately I ran into another error. And I cannot find
the location of the SQL statement.
Database error: Invalid SQL: 3
MySQL Error: 1064 (You have an error in your SQL syntax near '3' at line 1)
Session halted.
Follow-up Comments
*******************
-------------------------------------------------------
Date: Thu 09/18/2003 at 06:39 By: jarg
hey!! i think i found where is the error, in setup scripts, in
tables_update.inc.php when try to upgrade the addresses this code run:
$db1->query("INSERT INTO phpgw_contact_addr(contact_id,add1,
city, state, postal_code, country, tz, addr_type_id,
created_on, created_by, modified_on, modified_by) VALUES ("
. $GLOBALS['phpgw_setup']->oProc->f('org_id')
. ", '" .
$db1->db_addslashes($GLOBALS['phpgw_setup']->oProc->f('adr_one_street'))
." '" . ", '" .
$db1->db_addslashes($GLOBALS['phpgw_setup']->oProc->f('adr_one_locality'))
. "'" . ", '" .
$db1->db_addslashes($GLOBALS['phpgw_setup']->oProc->f('adr_one_region'))
." '" . ", '".
$db1->db_addslashes($GLOBALS['phpgw_setup']->oProc->f('adr_one_postalcode'))
." '". ", '" .
$db1->db_addslashes($GLOBALS['phpgw_setup']->oProc->f('adr_one_countryname'))
." '". ", " .
intval($GLOBALS['phpgw_setup']->oProc->f('tz'))
. ", " .
($GLOBALS['phpgw_setup']->oProc->f('addr_type_id'))?
$GLOBALS['phpgw_setup']->oProc->f('addr_type_id') : $addr_type
. ", " . $GLOBALS['phpgw_setup']->oProc->f('created_on')
. ", " . $GLOBALS['phpgw_setup']->oProc->f('created_by')
. ", " . $GLOBALS['phpgw_setup']->oProc->f('modified_on')
. ", " . $GLOBALS['phpgw_setup']->oProc->f('modified_by')
. ");");
and for any reason the sql which this want to run is '3' i think this 3 is the
addr_type_id, but i don't know why this concatenation only returns '3'.
i will review this later and try to fix, but probably bjohnson can help me in
this :P
-------------------------------------------------------
Date: Sat 09/13/2003 at 23:15 By: skwashd
Can you please try a CVS update - I think this one was fixed the other day.
CC list is empty
No files currently attached
For detailed info, follow this link:
http://savannah.gnu.org/bugs/?func=detailbug&bug_id=5245&group_id=509
_______________________________________________
Message sent via/by Savannah
http://savannah.gnu.org/
- [Phpgroupware-tracker] [bug #5245] Upgrade of existing DB fails, nobody, 2003/09/12
- [Phpgroupware-tracker] [bug #5245] Upgrade of existing DB fails, nobody, 2003/09/13
- [Phpgroupware-tracker] [bug #5245] Upgrade of existing DB fails,
nobody <=
- [Phpgroupware-tracker] [bug #5245] Upgrade of existing DB fails, nobody, 2003/09/18
- [Phpgroupware-tracker] [bug #5245] Upgrade of existing DB fails, nobody, 2003/09/18
- [Phpgroupware-tracker] [bug #5245] Upgrade of existing DB fails, nobody, 2003/09/18
- [Phpgroupware-tracker] [bug #5245] Upgrade of existing DB fails, nobody, 2003/09/18
- [Phpgroupware-tracker] [bug #5245] Upgrade of existing DB fails, nobody, 2003/09/18