Revisions for framework/Share/Share/sql.php

Location: [ Horde ] / framework / Share / Share / sql.php View: Logs | Branches | Statistics
Search Revisions:
Show diffs between and
Show Differences shows diffs to the previous revision. If you select a revision by clicking its row, Show Differences will show the differences to the selected row.
Show Branch:
  Revision Date Author Log Message
1.1.2.52 FRAMEWORK_3 (+2 -2 lines) 11/12/2008 02:29 PM Michael Rubinsky mrubinsk

MFH: 1.60, 1.61

1.61 (+2 -2 lines) 11/12/2008 02:25 PM Michael Rubinsky mrubinsk

actually, we should probably use the singleton method instead of factory here

1.60 (+2 -2 lines) 11/12/2008 02:21 PM Michael Rubinsky mrubinsk

Need a reference here

1.1.2.51 FRAMEWORK_3 (+23 -31 lines) 11/07/2008 11:53 AM Chuck Hagenbuch chuck

MFH:
1.59      +23 -31    framework/Share/Share/sql.php
1.1177    +2 -0      horde/docs/CHANGES

1.59 (+23 -31 lines) 11/06/2008 11:32 PM Chuck Hagenbuch chuck

[cjh] Don't use executeMultiple in the SQL Share driver when we might
reset the connection in between queries (Bug #7542).

1.1.2.50 FRAMEWORK_3 (+6 -3 lines) 10/25/2008 12:41 PM Michael Rubinsky mrubinsk

MFH:
1.58      +6 -3      framework/Share/Share/sql.php
1.48      +6 -3      framework/Share/Share/sql_hierarchical.php

1.58 (+6 -3 lines) 10/25/2008 12:36 PM Michael Rubinsky mrubinsk

array_walk can only modify the original value if the callback takes the value
as a reference. _db->quote() takes it by value so the change doesn't stick.
Bug: 6883

1.1.2.49 FRAMEWORK_3 (+4 -2 lines) 10/24/2008 10:10 AM Jan Schneider jan

MFH: 1.57

1.57 (+4 -2 lines) 10/24/2008 10:07 AM Jan Schneider jan

Run group ids through quote().

1.1.2.48 FRAMEWORK_3 (+7 -8 lines) 10/23/2008 05:28 PM Jan Schneider jan

MFH: Don't cast group_uid to integer (Bug #6883).

1.56 (+6 -6 lines) 10/23/2008 05:16 PM Jan Schneider jan

More casts removed. It would really help if people that report issues that we
can't reproduce would actually test our fixes!
Bug: 6883

1.55 (+2 -3 lines) 10/23/2008 05:11 PM Jan Schneider jan

Don't cast group ids to integers.
Bug: 6883

1.54 (+2 -2 lines) 10/06/2008 05:56 PM Michael Rubinsky mrubinsk

copy/paste error

1.53 (+3 -2 lines) 10/06/2008 05:49 PM Michael Rubinsky mrubinsk

Log at least these queries...

1.1.2.47 FRAMEWORK_3 (+2 -1 lines) 09/22/2008 06:22 PM Jan Schneider jan

MFH: 1.52

Tags: HORDE_3_3

1.52 (+2 -1 lines) 09/22/2008 06:15 PM Jan Schneider jan

Unset charset for the read database too. This has to be done in all places
where we use MDB2.

1.1.2.46 FRAMEWORK_3 (+3 -1 lines) 08/30/2008 10:44 AM Michael Rubinsky mrubinsk

MFH: MDB2 sequence changes

1.51      +3 -1      framework/Share/Share/sql.php
1.1       +84 -0     ingo/scripts/upgrades/2008-08-29_fix_mdb2_sequences.php (new)
1.1       +84 -0     kronolith/scripts/upgrades/2008-08-29_fix_mdb2_sequences.php (new)
1.1       +84 -0     mnemo/scripts/upgrades/2008-08-29_fix_mdb2_sequences.php (new)
1.1       +84 -0     nag/scripts/upgrades/2008-08-29_fix_mdb2_sequences.php (new)
1.1       +84 -0     turba/scripts/upgrades/2008-08-29_fix_mdb2_sequences.php (new)
1.1153    +1 -0      horde/docs/CHANGES
1.201     +2 -1      ingo/docs/CHANGES
1.467     +1 -0      kronolith/docs/CHANGES
1.142     +1 -0      mnemo/docs/CHANGES
1.235     +1 -0      nag/docs/CHANGES
1.450     +1 -0      turba/docs/CHANGES
1.8       +6 -2      ingo/docs/UPGRADING
1.11      +6 -2      kronolith/docs/UPGRADING
1.10      +6 -2      mnemo/docs/UPGRADING
1.9       +6 -2      nag/docs/UPGRADING
1.37      +6 -2      turba/docs/UPGRADING
1.9       +7 -2      ingo/docs/UPGRADING
1.12      +7 -2      kronolith/docs/UPGRADING
1.11      +7 -2      mnemo/docs/UPGRADING
1.10      +7 -2      nag/docs/UPGRADING
1.38      +7 -2      turba/docs/UPGRADING
1.2       +1 -49     ingo/scripts/upgrades/2008-08-29_fix_mdb2_sequences.php
1.2       +1 -49     kronolith/scripts/upgrades/2008-08-29_fix_mdb2_sequences.php
1.2       +1 -49     mnemo/scripts/upgrades/2008-08-29_fix_mdb2_sequences.php
1.2       +1 -49     nag/scripts/upgrades/2008-08-29_fix_mdb2_sequences.php
1.2       +1 -49     turba/scripts/upgrades/2008-08-29_fix_mdb2_sequences.php

Tags: HORDE_3_3_RC1

1.51 (+3 -1 lines) 08/29/2008 03:18 PM Michael Rubinsky mrubinsk

Have MDB2 use 'id' for sequence names -
Be sure to run the fix_mdb2_sequences upgrade script in the applications
that use sql shares.

1.1.2.45 FRAMEWORK_3 (+2 -2 lines) 08/08/2008 05:09 PM Michael Rubinsky mrubinsk

MFH: 1.50

1.50 (+2 -2 lines) 08/08/2008 04:57 PM Michael Rubinsky mrubinsk

data[share_id] won't exist if the share has not been saved, return NULL and
avoid array key not found warnings.

1.1.2.44 FRAMEWORK_3 (+17 -7 lines) 07/28/2008 11:57 AM Chuck Hagenbuch chuck

MFH 1.49

1.49 (+17 -7 lines) 07/28/2008 11:56 AM Chuck Hagenbuch chuck

- hack to fix s.* field names for sqlite. MDB2 is supposed to fix this for us, but doesn't.
- set consistent options on the read and write dbs.

1.1.2.43 FRAMEWORK_3 (+16 -1 lines) 07/25/2008 03:59 AM Jan Schneider jan

MFH

1.48 (+16 -1 lines) 07/24/2008 01:32 PM Jan Schneider jan

Always select the database before a query with MDB2. This matches DB's
behavior and is necessary in case the current database has changed from the
outside.
Bug: 6997

1.1.2.42 FRAMEWORK_3 (+8 -7 lines) 07/20/2008 10:22 AM Chuck Hagenbuch chuck

MFH:
1.47      +8 -7      framework/Share/Share/sql.php
1.34      +8 -10     framework/Share/Share/sql_hierarchical.php
1.1132    +1 -0      horde/docs/CHANGES

1.47 (+8 -7 lines) 07/20/2008 10:19 AM Chuck Hagenbuch chuck

SQL portability and quoting
Bug: 7084

1.46 (+1 -2 lines) 07/11/2008 01:17 AM Matt Selsky selsky

ws

1.1.2.41 FRAMEWORK_3 (+78 -48 lines) 07/11/2008 12:19 AM Michael Rubinsky mrubinsk

MFH:

1.44      +69 -48    framework/Share/Share/sql.php
1.33      +10 -2     framework/Share/Share/sql_hierarchical.php
1.45      +10 -1     framework/Share/Share/sql.php

1.45 (+10 -1 lines) 07/11/2008 12:12 AM Michael Rubinsky mrubinsk

No need to limit the results we free to those we get back from prepared
statements...free all result objects once we are done with them.

1.44 (+69 -48 lines) 07/10/2008 11:53 PM Michael Rubinsky mrubinsk

Commit a modified version of Selsky's patch for freeing prepared queries
and results.  I removed the $result->free() calls from the $result that
is returned from manipulation queries, as they don't return a MDB2_Result
object...

1.1.2.40 FRAMEWORK_3 (+3 -3 lines) 07/10/2008 02:59 PM Matt Selsky selsky

MFH: 1.43

1.43 (+3 -3 lines) 07/10/2008 02:44 PM Matt Selsky selsky

Log and return proper object.

1.1.2.39 FRAMEWORK_3 (+44 -20 lines) 07/10/2008 02:35 PM Michael Rubinsky mrubinsk

MFH:

1.40      +46 -19    framework/Share/Share/sql.php
1.30      +3 -3      framework/Share/Share/sql_hierarchical.php
1.31      +7 -1      framework/Share/Share/sql_hierarchical.php
1.41      +4 -8      framework/Share/Share/sql.php
1.32      +7 -7      framework/Share/Share/sql_hierarchical.php
1.42      +2 -1      framework/Share/Share/sql.php

1.42 (+2 -1 lines) 07/10/2008 02:30 PM Michael Rubinsky mrubinsk

oops.

1.41 (+4 -8 lines) 07/10/2008 02:26 PM Michael Rubinsky mrubinsk

Put these in _getShareCriteria()

1.40 (+46 -19 lines) 07/10/2008 01:32 PM Michael Rubinsky mrubinsk

clean up the _toDriver conversions.

1.1.2.38 FRAMEWORK_3 (+7 -3 lines) 07/10/2008 11:49 AM Michael Rubinsky mrubinsk

MFH: 1.39

1.39 (+7 -3 lines) 07/10/2008 11:45 AM Michael Rubinsky mrubinsk

Need to translate attribute keys

1.1.2.37 FRAMEWORK_3 (+22 -2 lines) 07/09/2008 03:26 AM Jan Schneider jan

MFH: 1.38

1.38 (+22 -2 lines) 07/09/2008 03:15 AM Jan Schneider jan

Catch errors from any prepare() call.

1.1.2.36 FRAMEWORK_3 (+2 -18 lines) 06/28/2008 06:21 PM Michael Rubinsky mrubinsk

MFH: 1.37

1.37 (+2 -18 lines) 06/28/2008 06:19 PM Michael Rubinsky mrubinsk

well, that was silly...we were looping through the tables we needed, we
just weren't using the right variable in the SQL statement.

1.1.2.35 FRAMEWORK_3 (+19 -1 lines) 06/28/2008 12:30 PM Michael Rubinsky mrubinsk

MFH: 1.36

1.36 (+19 -1 lines) 06/28/2008 12:29 PM Michael Rubinsky mrubinsk

Remove all user and group entrires for the deleted share.
Related to Bug: 6968

1.1.2.34 FRAMEWORK_3 (+3 -3 lines) 06/27/2008 11:18 AM Michael Rubinsky mrubinsk

MFH:
1.35      +3 -3      framework/Share/Share/sql.php
1.29      +2 -2      framework/Share/Share/sql_hierarchical.php

1.35 (+3 -3 lines) 06/27/2008 11:16 AM Michael Rubinsky mrubinsk

Need to use DISTINCT when both listing and counting shares, otherwise if
a share has more than one entry in a *_shares_users or *_shares_groups table
(as would be the case if you give explicit perms to more than one user/group)
the share will be returned / counted more than once in the results.

1.1.2.33 FRAMEWORK_3 (+3 -3 lines) 06/09/2008 07:56 PM Chuck Hagenbuch chuck

MFH 1.34

Tags: HORDE_3_2_2, HORDE_3_2_1

1.34 (+3 -3 lines) 06/09/2008 07:55 PM Chuck Hagenbuch chuck

only log errors
Bug: 6873

1.1.2.32 FRAMEWORK_3 (+2 -2 lines) 06/09/2008 01:37 PM Chuck Hagenbuch chuck

MFH:
1.33      +2 -2      framework/Share/Share/sql.php
1.1103    +2 -0      horde/docs/CHANGES

1.33 (+2 -2 lines) 06/09/2008 01:35 PM Chuck Hagenbuch chuck

[cjh] Fix deletion of SQL shares when using split read/write databases
(duck@obala.net, Bug #6870).

1.1.2.31 FRAMEWORK_3 (+3 -5 lines) 06/06/2008 12:13 PM Jan Schneider jan

MFH: 1.32

1.32 (+3 -5 lines) 06/06/2008 12:08 PM Jan Schneider jan

Remove more dead code.

1.1.2.30 FRAMEWORK_3 (+12 -8 lines) 06/06/2008 06:52 AM Jan Schneider jan

MFH: 1.31

1.31 (+12 -8 lines) 06/06/2008 06:50 AM Jan Schneider jan

$data['perm'] is not set here, so don't try to unset it.

1.1.2.29 FRAMEWORK_3 (+33 -1 lines) 06/01/2008 10:02 AM Michael Rubinsky mrubinsk

MFH:
1.30      +33 -1     framework/Share/Share/sql.php
1.23      +13 -4     framework/Share/Share/sql_hierarchical.php

1.30 (+33 -1 lines) 06/01/2008 09:55 AM Michael Rubinsky mrubinsk

More error checking and be sure to log any SQL errors

1.1.2.28 FRAMEWORK_3 (+16 -1 lines) 05/31/2008 04:08 PM Michael Rubinsky mrubinsk

MFH: 1.29

1.29 (+16 -1 lines) 05/31/2008 03:28 PM Michael Rubinsky mrubinsk

more error checking

1.1.2.27 FRAMEWORK_3 (+7 -2 lines) 05/31/2008 02:56 PM Michael Rubinsky mrubinsk

MFH: 1.27

1.28 (+7 -2 lines) 05/31/2008 02:54 PM Michael Rubinsky mrubinsk

Catch error

Bug: 6804

1.1.2.26 FRAMEWORK_3 (+6 -6 lines) 05/24/2008 01:48 PM Michael Rubinsky mrubinsk

MFH:
1.27      +6 -6      framework/Share/Share/sql.php
1.22      +6 -6      framework/Share/Share/sql_hierarchical.php

Tags: HORDE_3_2

1.27 (+6 -6 lines) 05/24/2008 01:40 PM Michael Rubinsky mrubinsk

More portable SQL bitwise comparisons.

Bug: 6751

1.1.2.25 FRAMEWORK_3 (+2 -4 lines) 05/12/2008 09:36 PM Michael Rubinsky mrubinsk

Looks like a merge went bad at some point...

1.26 (+1 -4 lines) 05/12/2008 09:35 PM Michael Rubinsky mrubinsk

ws

1.1.2.24 FRAMEWORK_3 (+39 -21 lines) 05/09/2008 04:15 PM Michael Rubinsky mrubinsk

MFH: 1.25

Tags: HORDE_3_2_RC4

1.25 (+39 -21 lines) 05/09/2008 04:13 PM Michael Rubinsky mrubinsk

fix numerous issues with share perms. Mostly fixes cases where a share has
a specific user and/or group permission set as well as a guest perm set. This
was causing everything but user/group permissions from being shown.

Also some issues where user and group perms were not being populated
correctly.

Testing welcome :)

1.1.2.23 FRAMEWORK_3 (+7 -7 lines) 05/07/2008 10:35 AM Michael Rubinsky mrubinsk

MFH: 1.24

1.24 (+7 -7 lines) 05/07/2008 10:28 AM Michael Rubinsky mrubinsk

One more DB -> MDB2 conversion along with a few formatting nits

Submitted by: Duck

1.1.2.22 FRAMEWORK_3 (+2 -2 lines) 05/02/2008 04:21 PM Chuck Hagenbuch chuck

MFH 1.23

1.23 (+2 -2 lines) 05/02/2008 04:17 PM Chuck Hagenbuch chuck

When sorting by name, we almost certainly want attribute_name, not
share_name (and we can get share_name by leaving the sort field as
null).

1.22 (+2 -1 lines) 05/02/2008 02:16 PM Michael Rubinsky mrubinsk

- Fix limiting shares by a particular user
- Use DISTINCT in countShares() (at least for now) to deal with the case where
a share owner might also be listed in the *_share_users table for the share.

1.1.2.21 FRAMEWORK_3 (+2 -2 lines) 04/30/2008 08:31 PM Michael Rubinsky mrubinsk

MFH: 1.21

1.21 (+2 -2 lines) 04/30/2008 08:31 PM Michael Rubinsky mrubinsk

Fix ->setLimit() call....it's not an assignment!

1.1.2.20 FRAMEWORK_3 (+2 -2 lines) 04/30/2008 07:12 PM Michael Rubinsky mrubinsk

MFH: 1.20

1.20 (+2 -2 lines) 04/30/2008 07:11 PM Michael Rubinsky mrubinsk

Fix variable name

1.1.2.19 FRAMEWORK_3 (+70 -76 lines) 04/30/2008 05:02 PM Michael Rubinsky mrubinsk

MFH: 1.19
SQL Shares now require MDB2

1.19 (+70 -76 lines) 04/30/2008 04:56 PM Michael Rubinsky mrubinsk

Change the sql share driver to use MDB2 instead of the old DB.

1.1.2.18 FRAMEWORK_3 (+37 -29 lines) 04/29/2008 03:33 PM Chuck Hagenbuch chuck

MFH:
1.18      +37 -29    framework/Share/Share/sql.php
1.6       +5 -5      ingo/scripts/sql/ingo.oci8.sql
1.9       +5 -5      ingo/scripts/sql/ingo.sql
1.7       +10 -2     ingo/scripts/upgrades/1.1_to_1.2.php
1.9       +5 -5      kronolith/scripts/sql/kronolith.mssql.sql
1.13      +5 -5      kronolith/scripts/sql/kronolith.mysql.sql
1.13      +5 -5      kronolith/scripts/sql/kronolith.oci8.sql
1.11      +5 -5      kronolith/scripts/sql/kronolith.pgsql.sql
1.11      +5 -5      kronolith/scripts/sql/kronolith.sql
1.6       +7 -7      kronolith/scripts/sql/kronolith.xml
1.5       +5 -5      kronolith/scripts/upgrades/2.1_to_2.2.pgsql.sql
1.8       +11 -2     kronolith/scripts/upgrades/2.1_to_2.2.php
1.5       +5 -5      kronolith/scripts/upgrades/2.1_to_2.2.sql
1.5       +5 -5      mnemo/scripts/sql/mnemo.mssql.sql
1.4       +5 -5      mnemo/scripts/sql/mnemo.oci8.sql
1.9       +5 -5      mnemo/scripts/sql/mnemo.sql
1.3       +7 -7      mnemo/scripts/sql/mnemo.xml
1.7       +10 -2     mnemo/scripts/upgrades/2.1_to_2.2.php
1.2       +5 -5      mnemo/scripts/upgrades/2.1_to_2.2.sql
1.11      +5 -5      nag/scripts/sql/nag.mssql.sql
1.11      +5 -5      nag/scripts/sql/nag.oci8.sql
1.15      +5 -5      nag/scripts/sql/nag.sql
1.7       +7 -7      nag/scripts/sql/nag.xml
1.7       +10 -2     nag/scripts/upgrades/2.1_to_2.2.php
1.3       +5 -5      nag/scripts/upgrades/2.1_to_2.2.sql
1.4       +5 -5      turba/scripts/sql/turba.mssql.sql
1.4       +5 -5      turba/scripts/sql/turba.oci8.sql
1.5       +5 -5      turba/scripts/sql/turba.pgsql.sql
1.4       +5 -5      turba/scripts/sql/turba.sql
1.4       +8 -8      turba/scripts/sql/turba.xml
1.2       +5 -5      turba/scripts/upgrades/2.1_to_2.2_add_sql_share_tables.mssql.sql
1.2       +5 -5      turba/scripts/upgrades/2.1_to_2.2_add_sql_share_tables.oci8.sql
1.2       +5 -5      turba/scripts/upgrades/2.1_to_2.2_add_sql_share_tables.pgsql.sql
1.2       +5 -5      turba/scripts/upgrades/2.1_to_2.2_add_sql_share_tables.sql
1.11      +10 -2     turba/scripts/upgrades/2.1_to_2.2_datatree_to_sql_share_migration.php

1.18 (+37 -29 lines) 04/29/2008 03:26 PM Chuck Hagenbuch chuck

- Rename "perm_extra" to "share_flags" because that's how it's being used
- adjust flags to be a real bitmask with constants
- Set perm_creator, perm_default, and perm_guest to 0 (no perms) by default
- Adjust code accordingly

1.1.2.17 FRAMEWORK_3 (+14 -13 lines) 04/28/2008 12:15 PM Michael Rubinsky mrubinsk

MFH: 1.17

1.17 (+14 -13 lines) 04/28/2008 12:13 PM Michael Rubinsky mrubinsk

Don't overwrite the perms array if it already exists

1.1.2.16 FRAMEWORK_3 (+2 -2 lines) 04/26/2008 02:35 PM Michael Rubinsky mrubinsk

MFH: 1.16

1.16 (+2 -2 lines) 04/26/2008 02:19 PM Michael Rubinsky mrubinsk

We are joing the groups table with the shares table, not with itself.

1.1.2.15 FRAMEWORK_3 (+6 -1 lines) 04/25/2008 08:55 PM Michael Rubinsky mrubinsk

MFH: 1.15

1.15 (+6 -1 lines) 04/25/2008 08:51 PM Michael Rubinsky mrubinsk

Convert charset if needed on the attributes we're filtering on.

1.1.2.14 FRAMEWORK_3 (+58 -16 lines) 04/25/2008 07:23 PM Michael Rubinsky mrubinsk

MFH: 1.14

1.14 (+58 -16 lines) 04/25/2008 06:51 PM Michael Rubinsky mrubinsk

Make sure we convert from/to the SQL server's charset when needed.
Still need to check the conversion on any attributes we pass in to search
by.

1.1.2.13 FRAMEWORK_3 (+27 -17 lines) 04/25/2008 02:57 AM Chuck Hagenbuch chuck

MFH 1.13

1.13 (+27 -17 lines) 04/25/2008 02:56 AM Chuck Hagenbuch chuck

Get the list of columns for the specific share table; sqlite at least
returns columns as 's.share_id' instead of 'share_id' if we do SELECT
s.*, so this works around that.

1.1.2.12 FRAMEWORK_3 (+1 -21 lines) 04/24/2008 04:33 PM Michael Rubinsky mrubinsk

MFH: 1.12

1.12 (+1 -21 lines) 04/24/2008 04:32 PM Michael Rubinsky mrubinsk

remove dead code

1.1.2.11 FRAMEWORK_3 (+19 -4 lines) 04/23/2008 05:05 PM Michael Rubinsky mrubinsk

MFH`

1.11 (+19 -4 lines) 04/23/2008 04:59 PM Michael Rubinsky mrubinsk

Allow paging of results from a listShares() call

1.1.2.10 FRAMEWORK_3 (+31 -17 lines) 04/23/2008 01:42 PM Michael Rubinsky mrubinsk

MFH: 1.20 1.10

1.10 (+31 -17 lines) 04/23/2008 01:23 PM Michael Rubinsky mrubinsk

Add ability to have Horde_Share_Object be instantiated as an arbitrary
sub-class

1.1.2.9 FRAMEWORK_3 (+3 -1 lines) 04/23/2008 09:50 AM Michael Rubinsky mrubinsk

MFH: 1.9

1.9 (+3 -1 lines) 04/22/2008 05:48 PM Michael Rubinsky mrubinsk

Need to set the share object here

1.1.2.8 FRAMEWORK_3 (+15 -17 lines) 04/17/2008 12:05 PM Chuck Hagenbuch chuck

MFH 1.8

1.8 (+15 -17 lines) 04/17/2008 12:04 PM Chuck Hagenbuch chuck

Always need these checks.

1.1.2.7 FRAMEWORK_3 (+1 -61 lines) 04/16/2008 11:00 PM Chuck Hagenbuch chuck

MFH 1.7

1.7 (+1 -61 lines) 04/16/2008 10:41 PM Chuck Hagenbuch chuck

Remove commented-out and unused code (I can see the point, but we
should just provide a straight list() with no objects function instead
of having alternate objects, imo).

1.1.2.6 FRAMEWORK_3 (+38 -17 lines) 04/12/2008 09:40 PM Chuck Hagenbuch chuck

MFH 1.6

Only showing the 100 latest revisions. Show all revisions? (may take a while).