Hi there,

You use REGEX to check against a regular expression which is available in PostgreSQL, but not with that syntax. If I'm correct, they use the ~ operator. I just never use it since it's not compatible.

You can replace them all with a LIKE since all are '^something' and this equivalent to 'something%' with the LIKE keyword (which is common to all the database systems.)

Also, the $and variable in private_upload_views_handler_all_files() is used so needs to be defined no matter what (to avoid E_NOTICEs...) I included that small fix too.

Thank you.
Alexis Wilke

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

rmcom’s picture

Assigned: AlexisWilke » Unassigned
Status: Needs review » Active

I am also running postgresql and would be very grateful if somebody could look at this patch.

I have applied this patch and the patch provided here http://drupal.org/node/280742 but both patches do not fit onto the current dev version and other versions I have tried.

It seems like this issue was already fixed here http://drupal.org/node/280742 but as the code evolved, it seems the dev version needs fixing to be compatible with postgresql again.

The following link from the thread at http://drupal.org/node/280742 may be useful: http://www.postgresql.org/docs/8.3/static/functions-matching.html

rmcom’s picture

After some googling I also found these two patches (at the end of the original post) that may help:

http://drupal.org/node/974872

rmcom’s picture

Version: 6.x-1.x-dev » 6.x-1.0-rc3

PostgreSQL compatibility would be essential for the success of this module.

Could it be integrated into the next RC?

rmcom’s picture

Category: bug » support
rmcom’s picture

Category: bug » support
Status: Patch (to be ported) » Active
FileSize
3.92 KB

The patch was not working (neither for for the current 6.x dev code nor for 6.x-1.0-rc3) because the line numbers did not match.

Otherwise the patch from above works. I have fixed the line numbers and am uploading the patch that makes 6.x-1.0-rc3 compatible with Postgresql.

Please
- refrain from using the command REXEP in the future and use LIKE because it works for MySQL and Postgresql (see patch code, above comment by AlexisWilke, and http://drupal.org/node/280742 for details)

Please
- roll this patch into the 6.x code to create rc4

Hope this helps all who had the same problem. And thank you to AlexisWilke for providing the original patch.

rmcom’s picture

Category: support » bug
Status: Active » Patch (to be ported)

Status: Active » Patch (to be ported)