Add user page contains Warnings
Running 6.14
I went to add a new user "Administer > User management > Users > Add user" and got the following warnings in a pink box at the top of the page:
* warning: array_fill() [function.array-fill]: Number of elements must be positive in /htdocs/drupal/includes/database.inc on line 253.
* warning: implode() [function.implode]: Bad arguments. in /htdocs/drupal/includes/database.inc on line 253.
* warning: array_keys() [function.array-keys]: The first argument should be an array in /htdocs/drupal/modules/user/user.module on line 502.
* user warning: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ')' at line 1 query: SELECT p.perm FROM role r INNER JOIN permission p ON p.rid = r.rid WHERE r.rid IN () in /htdocs/drupal/modules/user/user.module on line 502.
How do I resolve this issue?

=-=
very odd.
what contributed modules are in use?
Administration Enabled Name V
Administration
Enabled Name Version Description
Enabled Name Version Description
Administration menu 6.x-1.5 Provides a dropdown menu to most administrative tasks and other common destinations (to users with the proper permissions).
CCK
Enabled Name Version Description
Enabled Name Version Description
Content 6.x-2.5 Allows administrators to define new content types.
Required by: Content Copy (enabled), Content Permissions (enabled), Fieldgroup (enabled), Node Reference (enabled), Number (enabled), Option Widgets (enabled), Text (enabled), User Reference (enabled)
Content Copy 6.x-2.5 Enables ability to import/export field definitions.
Depends on: Content (enabled)
Content Permissions 6.x-2.5 Set field-level permissions for CCK fields.
Depends on: Content (enabled)
Fieldgroup 6.x-2.5 Create display groups for CCK fields.
Depends on: Content (enabled)
Node Reference 6.x-2.5 Defines a field type for referencing one node from another.
Depends on: Content (enabled), Text (enabled), Option Widgets (enabled)
Number 6.x-2.5 Defines numeric field types.
Depends on: Content (enabled)
Option Widgets 6.x-2.5 Defines selection, check box and radio button widgets for text and numeric fields.
Depends on: Content (enabled)
Required by: Node Reference (enabled), User Reference (enabled)
Text 6.x-2.5 Defines simple text field types.
Depends on: Content (enabled)
Required by: Node Reference (enabled), User Reference (enabled)
User Reference 6.x-2.5 Defines a field type for referencing a user from a node.
Depends on: Content (enabled), Text (enabled), Option Widgets (enabled)
Core - optional
Enabled Name Version Description
Enabled Name Version Description
Aggregator 6.14 Aggregates syndicated content (RSS, RDF, and Atom feeds).
Blog 6.14 Enables keeping easily and regularly updated user web pages or blogs.
Blog API 6.14 Allows users to post content using applications that support XML-RPC blog APIs.
Book 6.14 Allows users to structure site pages in a hierarchy or outline.
Color 6.14 Allows the user to change the color scheme of certain themes.
Comment 6.14 Allows users to comment on and discuss published content.
Required by: Forum (disabled), Tracker (disabled)
Contact 6.14 Enables the use of both personal and site-wide contact forms.
Content translation 6.14 Allows content to be translated into different languages.
Depends on: Locale (disabled)
Database logging 6.14 Logs and records system events to the database.
Forum 6.14 Enables threaded discussions about general topics.
Depends on: Taxonomy (enabled), Comment (enabled)
Help 6.14 Manages the display of online help.
Locale 6.14 Adds language handling functionality and enables the translation of the user interface to languages other than English.
Required by: Content translation (disabled)
Menu 6.14 Allows administrators to customize the site navigation menu.
OpenID 6.14 Allows users to log into your site using OpenID.
Path 6.14 Allows users to rename URLs.
Required by: Pathauto (enabled)
PHP filter 6.14 Allows embedded PHP code/snippets to be evaluated.
Ping 6.14 Alerts other sites when your site has been updated.
Poll 6.14 Allows your site to capture votes on different topics in the form of multiple choice questions.
Profile 6.14 Supports configurable user profiles.
Search 6.14 Enables site-wide keyword searching.
Statistics 6.14 Logs access statistics for your site.
Syslog 6.14 Logs and records system events to syslog.
Taxonomy 6.14 Enables the categorization of content.
Required by: Forum (disabled), XML sitemap taxonomy (enabled)
Throttle 6.14 Handles the auto-throttling mechanism, to control site congestion.
Tracker 6.14 Enables tracking of recent posts for users.
Depends on: Comment (enabled)
Trigger 6.14 Enables actions to be fired on certain system events, such as when new content is created.
Update status 6.14 Checks the status of available updates for Drupal and your installed modules and themes.
Upload 6.14 Allows users to upload and attach files to content.
Core - required
Enabled Name Version Description
Enabled Name Version Description
Block 6.14 Controls the boxes that are displayed around the main content.
Filter 6.14 Handles the filtering of content in preparation for display.
Required by: SpamSpan (enabled)
Node 6.14 Allows content to be submitted to the site and displayed on pages.
System 6.14 Handles general site configuration for administrators.
User 6.14 Manages the user registration and login system.
Domain Access
Enabled Name Version Description
Enabled Name Version Description
Domain Access 6.x-2.0-rc9 A domain-based access control system
Required by: Domain Alias (enabled), Domain Configuration (enabled), Domain Content (enabled), Domain Navigation (enabled), Domain Prefix (enabled), Domain Source (enabled), Domain Strict (enabled), Domain Theme (enabled), Domain User (enabled), Domain Views (enabled)
Domain Alias 6.x-2.0-rc9 Advanced domain matching methods for Domain Access.
Depends on: Domain Access (enabled)
Domain Configuration 6.x-2.0-rc9 Advanced site configuration options for Domain Access.
Depends on: Domain Access (enabled)
Domain Content 6.x-2.0-rc9 Provides a content batch editing screen for each active domain.
Depends on: Domain Access (enabled)
Domain Navigation 6.x-2.0-rc9 Navigation block and menu options for Domain Access
Depends on: Domain Access (enabled)
Domain Prefix 6.x-2.0-rc9 Interface for selective table prefixing for use with Domain Access.
Depends on: Domain Access (enabled)
Domain Source 6.x-2.0-rc9 Creates a source domain for linking to content from other domains.
Depends on: Domain Access (enabled)
Domain Strict 6.x-2.0-rc9 Forces users to be assigned to a domain in order to view content on that domain.
Depends on: Domain Access (enabled)
Domain Theme 6.x-2.0-rc9 Assign themes to domains created by the Domain Access module
Depends on: Domain Access (enabled)
Domain User 6.x-2.0-rc9 Creates unique subdomains for registered users.
Depends on: Domain Access (enabled)
Domain Views 6.x-2.0-rc9 Provides Views integration for the Domain Access module.
Depends on: Domain Access (enabled), Views (enabled)
Input filters
Enabled Name Version Description
Enabled Name Version Description
SpamSpan 6.x-1.4 The SpamSpan module obfuscates email addresses to help prevent spambots from collecting them. It implements the technique at http://www.spamspan.com.
Depends on: Filter (enabled)
Mail
Enabled Name Version Description
Enabled Name Version Description
SMTP Authentication Support 6.x-1.0-beta3 Allows the sending of site e-mail through an SMTP server of your choice.
Other
Enabled Name Version Description
Enabled Name Version Description
Advanced help 6.x-1.2 Allow advanced help and documentation.
Required by: Advanced help example (enabled)
Advanced help example 6.x-1.2 A example help module to demonstrate the advanced help module.
Depends on: Advanced help (enabled)
IMCE 6.x-1.3 An image/file uploader and browser supporting personal directories and user quota.
Pathauto 6.x-1.2 Provides a mechanism for modules to automatically generate aliases for the content they manage.
Depends on: Path (enabled), Token (enabled)
Scheduler 6.x-1.6 This module allows nodes to be published and unpublished on specified dates.
Token 6.x-1.12 Provides a shared API for replacement of textual placeholders with actual data.
Required by: Pathauto (enabled), TokenSTARTER (enabled), Token actions (enabled)
Token actions 6.x-1.12 Provides enhanced versions of core Drupal actions using the Token module.
Depends on: Token (enabled)
TokenSTARTER 6.x-1.12 Provides additional tokens and a base on which to build your own tokens.
Depends on: Token (enabled)
Webform 6.x-2.8 Enables the creation of forms and questionnaires.
User interface
Enabled Name Version Description
Enabled Name Version Description
Wysiwyg 6.x-2.0 Allows users to edit contents with client-side editors.
Views
Enabled Name Version Description
Enabled Name Version Description
Views 6.x-2.6 Create customized lists and queries from your database.
Required by: Domain Views (enabled), Views exporter (enabled), Views UI (enabled)
Views exporter 6.x-2.6 Allows exporting multiple views at once.
Depends on: Views (enabled)
Views UI 6.x-2.6 Administrative interface to views. Without this module, you cannot create or edit your views.
Depends on: Views (enabled)
XML sitemap
Enabled Name Version Description
Enabled Name Version Description
XML sitemap 6.x-1.1 Create a XML sitemap conforming to sitemaps.org specifications.
Required by: XML sitemap engines (enabled), XML sitemap node (enabled), XML sitemap taxonomy (enabled), XML sitemap user (enabled)
XML sitemap engines 6.x-1.1 Submit the sitemap to search engines.
Depends on: XML sitemap (enabled)
XML sitemap node 6.x-1.1 Add node links to the sitemap.
Depends on: XML sitemap (enabled)
XML sitemap taxonomy 6.x-1.1 Add taxonomy term links to the sitemap.
Depends on: Taxonomy (enabled), XML sitemap (enabled)
XML sitemap user 6.x-1.1 Add user profile links to the sitemap.
Depends on: XML sitemap (enabled)
So I proceeded to add the new
So I proceeded to add the new user.
I received my customized welcome email.
I can login to Drupal.
But the return page after I added the user had this message in the pink box:
* warning: array_fill() [function.array-fill]: Number of elements must be positive in /htdocs/drupal/includes/database.inc on line 253.
* warning: implode() [function.implode]: Bad arguments. in /htdocs/drupal/includes/database.inc on line 253.
* warning: array_keys() [function.array-keys]: The first argument should be an array in /htdocs/drupal/modules/user/user.module on line 502.
* user warning: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ')' at line 1 query: SELECT p.perm FROM role r INNER JOIN permission p ON p.rid = r.rid WHERE r.rid IN () in /htdocs/drupal/modules/user/user.module on line 502.
* warning: array_fill() [function.array-fill]: Number of elements must be positive in /htdocs/drupal/includes/database.inc on line 253.
* warning: implode() [function.implode]: Bad arguments. in /htdocs/drupal/includes/database.inc on line 253.
* warning: array_keys() [function.array-keys]: The first argument should be an array in /htdocs/drupal/modules/user/user.module on line 502.
* user warning: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ')' at line 1 query: SELECT p.perm FROM role r INNER JOIN permission p ON p.rid = r.rid WHERE r.rid IN () in /htdocs/drupal/modules/user/user.module on line 502.
=-=
as far as I can tell, this isn't present in a standard 6.14 installation. I can't reproduce on any live site nor any sandbox site.
That said, disable contrib modules one at a time until you can locate the one that may be causing the static.
ok...meaning I have a
ok...meaning I have a non-standard install? Maybe that's why Clean URL's don't work ;)
=-=
standard was bad wording on my part. It's not a default install void of contributed modules.
Ok, I disabled and enabled
Ok, I disabled and enabled each Contrib Mod and determined Domain Access is the culprit.
Domain Access is a key module for us. If we can't run multiple domains in 1 instance of Drupal to share common content, then that becomes a show stopper for us.
=-=
check the issue queue of the module in question for similar reports. Ensure you are using the latest version.
Test on a test site the -dev version if the error is still persistent or disappears file a bug report in the issue queue of the module in question.
The developer is a long time contributor and typically reacts pretty quickly to issues on his modules.
Reported issue. I have to
Reported issue.
I have to turn Domain Access back on because the Domain I was working on to learn how to convert my pages from an existing site is longer present in Drupal. I hope by turning Domain Access back on that the domain, the themes directory, and the page I was building comes back.
They're back.
They're back. I'll just live with the pink box warning messages until the contributor-developer can address the issue.