Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
This module lacked a postgresql schema and code in the .install to put it into a postgresql database. I've remedied this.
I've written in the postgresql schema into a .pgsql file as well as into the masquerade.install file. Written based on the 4.7.0 release. You can download it here and try it out. Let me know when this is integrated into a new release version.
Comment | File | Size | Author |
---|---|---|---|
#21 | masquerade.module.og_support.patch | 804 bytes | PMunn |
#14 | masquerade.install.patch | 1.07 KB | Gurpartap Singh |
#12 | masquerade.install.pgsql.patch | 764 bytes | PMunn |
#9 | masquerade.postgresql_0.patch | 1.41 KB | PMunn |
#8 | masquerade_masquerade.module_og_support_0.patch | 803 bytes | PMunn |
Comments
Comment #1
PMunn CreditAttribution: PMunn commentedI've added in the code change starbow noted on the OG compatibility page into the zip file on my file archive above and given it a timestamp of today. I haven't done any testing of his change.
Comment #2
PMunn CreditAttribution: PMunn commentedHere's a patch for the entire masquerade directory to enable postgresql and og support. Execute the patch from outside the masquerade directory.
Comment #3
PMunn CreditAttribution: PMunn commentedThe two features are distinct from each other -- postgresql support changes don't overlap the OG support patches.
So I'm posting them separately for review and (hopefully) inclusion, having rebuilt them from the most recent .tar.gz.
Here is the postgresql patch.
Comment #4
PMunn CreditAttribution: PMunn commentedAnd this is the OG support patch, which is Starbow's hack from another thread, as mentioned elsewhere, but applied to the latest .tar.gz file for masquerade.
Comment #5
Tobias Maier CreditAttribution: Tobias Maier commentedshould be
please remove all your comments like this one:
consider how wasted our code would be if we would add such fragments everywhere
but thanks in general for your work
Comment #6
PMunn CreditAttribution: PMunn commentedThank you for the feedback. Here are the updated postgresql and og patches zipped together.
Comment #7
Tobias Maier CreditAttribution: Tobias Maier commentedit is better not to zip them because it is more work to review them.
attach them on two comments
the og patch is not idented the right way (I hope this was the right word :/ )
cu
Comment #8
PMunn CreditAttribution: PMunn commentedHere is the og patch, with indenting corrected.
Comment #9
PMunn CreditAttribution: PMunn commentedAnd here is the postgresql patch, separated from the zip file.
Comment #10
PMunn CreditAttribution: PMunn commentedHi folks. It's already October. Can someone step in and apply this patch or at least test it more fully for application to the CVS version? I'd like to have this issue closed up soon since it touches on one of the more popular modules (OG), and so I can start using it on my own site(s).
Comment #11
Gurpartap Singh CreditAttribution: Gurpartap Singh commentedCan you please resubmit a patch for masquerade.install file, providing the pgsql database only. I'll review and commit after it.
Comment #12
PMunn CreditAttribution: PMunn commentedHere is the masquerade.install only patch.
The only difference between this patch and the previous one I posted is I snipped out the references to masquerade.pgsql, which didn't used to exist.
Comment #13
Gurpartap Singh CreditAttribution: Gurpartap Singh commentedThank you PMunn
Comment #14
Gurpartap Singh CreditAttribution: Gurpartap Singh commentedI had requested someone to review the pgsql import code over IRC. I was suggested to revert table names format {masquerade} to "masquerade". Updated patch with that.
Also, shouldn't int() be used instead of numeric()?
Comment #15
PMunn CreditAttribution: PMunn commentedThat quoted-tablename PHP doesn't look like it'll work.
Why would you undo the braces on the patch? It runs just fine.
There is no "int()" in PostgreSQL, just "integer". The numeric type allows you to specify the precision.
For an overview, see this documentation page on integer and arbitrary-precision number types.
Comment #16
Gurpartap Singh CreditAttribution: Gurpartap Singh commentedI am not familiar to postgresql. So it's your responsibility further issues arising with it ;). I'll commit it today.
Comment #17
Gurpartap Singh CreditAttribution: Gurpartap Singh commentedLast patch(PMunn's) is into cvs now. ;-)
Comment #18
merlinofchaos CreditAttribution: merlinofchaos commentedThe {} is a Drupalism and it allows db_query to support table indices. It should not be removed.
Comment #19
Gurpartap Singh CreditAttribution: Gurpartap Singh commentedSomeone over #postgresql suggested "tablename" is generic than curlies around them. but..
Drupal way :)
Comment #20
PMunn CreditAttribution: PMunn commentedI've tested today's CVS version with a new drupal install and an existing one (on PostgreSQL) and finds it works as advertised. I'll prepare a new, og compatibility patch if necessary and post it here for review.
Comment #21
PMunn CreditAttribution: PMunn commentedThis patch implementing organic groups support in masquerade is nearly identical to the last-posted one with a slight change in line numbers to reflect changes in the CVS code base. I'm having a very hard time getting my mind around configuring organic groups in my dev/sandbox drupal site so I haven't been able to test it yet. Other testers are welcome, but I did have the previous, identical version working fine in another sandbox at one point so I'm confident this one will do well overall.
Comment #22
Gurpartap Singh CreditAttribution: Gurpartap Singh commentedWhat's the conflict between OG and Masquerade? Is it user_load(), I guess?
Changing issue to active for OG case.
Comment #23
PMunn CreditAttribution: PMunn commentedHere's the issue I drew from back when I opened the thread.
http://drupal.org/node/62278
I should retest and see if my patch is needed or not with the latest masquerade code. I'm guessing it isn't but I'll look into it.
Comment #24
Gurpartap Singh CreditAttribution: Gurpartap Singh commentedThat issue has been fixed.. Need to test for current code.
Comment #25
Gurpartap Singh CreditAttribution: Gurpartap Singh commentedComment #26
PMunn CreditAttribution: PMunn commentedA few cursory tests of this patched version (cvs version) shows it working just fine on my postgresql configurations.
Thanks to everyone for reviewing and posting the code.
Comment #27
Gurpartap Singh CreditAttribution: Gurpartap Singh commentedThanks all dears :). Please make this issue active, if any unexpected case persists. Thanks again PMunn
Comment #28
(not verified) CreditAttribution: commented