Browse
 
Tools Add
Rss Categories
-->

Configuring FTP User Isolation in IIS 7 and IIS 8

Reference Number: AA-04668 Created: 2012-12-20 17:23 Last Updated: 2013-05-03 18:46 0 Rating/ Voters

Microsoft has created a new FTP service that has been completely rewritten for Windows Server 2008. This new FTP service incorporates many new features that enable web authors to publish content better than before, and offers web administrators more security and deployment options.

This document will walk you through the various FTP user isolation settings using the new FTP user interface and by directly editing the IIS configuration files.

Note: This walk-through contains a series of steps where you will be logging in to your FTP site using the local administrator account. These steps should only be followed on the server itself using the loopback address or over SSL from a remote server. If you prefer to use a separate user account instead of the administrator account, you will need to create the appropriate folders and set the correct permissions for that user account when necessary.

First Steps

The following items are required to complete the procedures in this article:

  1. IIS 7 must be installed on your Windows Server 2008 RC0 server, and the Internet Information Services Manager must be installed.
  2. The new FTP service must be installed. You can download and install the FTP service from the http://www.iis.net/ web site using one of the following links:
  3. You will need to create a root folder for FTP publishing:
    • Create a folder at "%SystemDrive%\inetpub\ftproot"
    • Set the permissions to allow anonymous access:
    • Open a command prompt.
    • Type the following command:
    ICACLS "%SystemDrive%\inetpub\ftproot" /Grant IUSR:R /T
    • Close the command prompt.
  4. You will need to create additional content folders:
    • Create a folder at "%SystemDrive%\inetpub\ftproot\LocalUser\Public"
    • Create a folder at "%SystemDrive%\inetpub\adminfiles"


Using the FTP Site Wizard to Create an FTP site

In this first section we will create a new FTP site that can be opened for Read-only access by anonymous users and Read/Write access by the administrator account.

  1. In IIS Manager, in the Connections pane, click the Sites node in the tree.
  2. As shown in the image below, right-click the Sites node in the tree and click Add FTP Site, or click Add FTP Site in the Actions pane.
  3. When the Add FTP Site wizard appears:
    • Enter "My New FTP Site" in the FTP site name box, then navigate to the "%SystemDrive%\inetpub\ftproot" folder that you created in the Prerequisites section. Note that if you choose to type in the path to your content folder, you can use environment variables in your paths.
    • When you have completed these items, click Next.
  4. On the next page of the wizard:
    • You would normally choose an IP address for your FTP site from the IP Address drop-down, or you could choose to accept the default selection of "All Unassigned." Because you will be using the administrator account later in this walk-through, you want to make sure that you restrict access to the server and enter the local loopback IP address for your computer by typing "127.0.0.1" in the IP Address box.
    • You would normally enter the TCP/IP port for the FTP site in the Port box. For this walk-through, you will choose to accept the default port of 21.
    • For this walk- through, you will not use a host name, so make sure that the Virtual Host box is blank.
    • Make sure that the Certificates drop-down is set to "Not Selected" and that the Allow SSL option is selected.
    • When you have completed these items, click Next.


  5. On the next page of the wizard:
    • Select Anonymous for the Authentication settings.
    • For the Authorization settings, choose "Anonymous users" from the Allow access to drop-down, and select Read for the Permissions option.
    • When you have completed these items, click Finish.
  6. In IIS Manager, click the node for the FTP site that you created; this will display the icons for all of the FTP features.
  7. We need to add Basic Authentication so that users can log in. To do so, double-click the FTP Authentication icon to open the FTP authentication feature page.
  8. When the FTP Authentication page is displayed, highlight Basic Authentication and then click Enable in the Actions pane.
  9. In IIS Manager, click the node for the FTP site to re-display the icons for all of the FTP features.
  10. We need to add an authorization rule so that the administrator can log in. To do so, double-click the FTP Authorization Rules icon to open the FTP authorization rules feature page.
  11. When the FTP Authorization Rules page is displayed, click Add Allow Rule in the Actions pane.
  12. When the Add Allow Authorization Rule dialog box is displayed
    • Select Specified users, then type "administrator" in the box.
    • For Permissions, select both Read and Write.
    • When you have completed these items, click OK.

Configuring User Isolation Settings by Physical Directories

When isolating users by physical directories only, all FTP user sessions are restricted to the physical directory with the same name of the FTP user account. However, any global virtual directories that are created will apply to all users.

  1. In IIS Manager, click the node for the FTP site that you created; this will display the icons for all of the FTP features.
  2. Double-click the FTP User Isolation icon to open the FTP user isolation feature.
  3. When the FTP User Isolation feature page is displayed, select the User name physical directory (enable global virtual directories) option, then click Apply in the Actions pane.

Logging in to your FTP site

You can now log in to your FTP site using user isolation, but the following information applies:

  1. If you log in to your FTP site anonymously, your session will be restricted to the "LocalUser\Public" folder that you created in the Prerequisites section.
  2. If you attempt to log in to your FTP site using the administrator account, your logon request will be denied because the administrator account does not have a home directory defined. To allow the administrator account to log in you would need to create a home directory for the administrator account at "%SystemDrive%\inetpub\ftproot\LocalUser\Administrator". After which, if you logged in to your FTP site using the administrator account, your session will be restricted to the "LocalUser\Administrator" folder that you just created.


Configuring User Isolation Settings for All Directories

When isolating users for all directories, all FTP user sessions are restricted to the physical or virtual directory with the same name of the FTP user account. In addition, all global virtual directories that are created will be ignored. In this step you will configure user isolation for all directories, and add a virtual directory for the administrator user.

  1. In IIS Manager, click the node for the FTP site that you created; this will display the icons for all of the FTP features.
  2. Double-click the FTP User Isolation icon to open the FTP user isolation feature.
  3. When the FTP User Isolation feature page is displayed, select the User name directory (disable global virtual directories) option, then click Apply in the Actions pane.
  4. Expand the tree node for your FTP site, then right-click the LocalUser folder and click Add Virtual Directory. (Note: In this example the "LocalUser" folder is a physical directory, but a virtual directory could also have been used.)
  5. When the Add Virtual Directory dialog box appears:
    • Enter "administrator" for the Alias.
    • Enter "%SystemDrive%\inetpub\adminfiles" for the Physical path.
    • When you have completed these items, click OK.


Logging in to your FTP site

You can now log in to your FTP site using user isolation, but the following information applies:

  1. As with Step 3, if you log in to your FTP site anonymously, your session will be restricted to the "LocalUser\Public" folder that you created in the Prerequisites section.
  2. If you log in to your FTP site using the administrator account, your session will be restricted to the "/LocalUser/administrator" virtual directory that you just created.
Rss Comments
  • There are no comments for this article.
Info Add Comment
Nickname: Your Email: Subject: Comment:
0.0049710273742676
SELECT `sys_settings`.`var_name`, `sys_settings`.`var_value` FROM `sys_settings`
0.00075197219848633
SELECT `languages`.`lang_id` FROM `languages` WHERE (lang = 'def')
0.007598876953125
SELECT `languages_vars`.`language_var`, `languages_vars`.`value` FROM `languages_vars` WHERE (lang_id = 1) AND (type != 'notification')
0.0092871189117432
SELECT `languages_vars`.`language_var`, `languages_vars`.`value` FROM `languages_vars` WHERE (lang_id = 1) AND (type != 'notification')
0.00077605247497559
SELECT `sys_settings`.`var_value` FROM `sys_settings` WHERE (var_name = 'session_life_time_unlimited')
0.00085878372192383
SELECT `ac`.`auto_relate`, `ac`.`max_staff_users`, `ac`.`max_client_users`, `ac`.`name`, (SELECT COUNT(*) FROM `users` WHERE (account_id = 2) AND (ldap_user = 'Y')) AS `ldap_users_num` FROM `accounts` AS `ac` WHERE (ac.account_id = 2)
0.00063610076904297
SELECT COUNT(us.user_id) FROM `users` AS `us` WHERE (type   = 'staff') AND (active = 'Y') AND (account_id = 2) AND ((SELECT COUNT(*) FROM `users_groups` AS `ug` WHERE (ug.user_id = us.user_id)) > 0) AND (login != 'sales@web-site-scripts.com')
0.00075912475585938
SELECT COUNT(us.user_id) FROM `users` AS `us` WHERE (type   = 'client') AND (active = 'Y') AND (account_id = 2) AND ((SELECT COUNT(*) FROM `users_groups` AS `ug` WHERE (ug.user_id = us.user_id)) > 0) AND (login != 'sales@web-site-scripts.com')
0.00082588195800781
SELECT COUNT(us.user_id) FROM `users` AS `us` WHERE (account_id = 2) AND ((SELECT COUNT(*) FROM `users_groups` AS `ug` WHERE (ug.user_id = us.user_id)) = 0) AND (login != 'sales@web-site-scripts.com')
0.00045895576477051
SELECT COUNT(*) AS `count` FROM `accounts` WHERE (LOWER(name) != 'preview')
0.00044107437133789
SELECT `accounts`.`name` FROM `accounts` WHERE (LOWER(name) != 'preview') ORDER BY `account_id` ASC LIMIT 1
0.0010390281677246
SELECT `view_manage`.`view_id`, `view_manage`.`name` FROM `view_manage` WHERE (type       = 'Hosted') AND (account_id = 2)
0.00098514556884766
SELECT `vm`.`view_id` AS `id`, `vm`.`name`, `vm`.`type`, `vm`.`hash`, `vm`.`settings` AS `tabs`, `vm`.`style_id` AS `styles`, `vm`.`gmt`, `vm`.`time_format`, `vm`.`date_format`, `vm`.`lang_id`, `vm`.`status`, `vm`.`access_mode`, `vm`.`voting_id` AS `voting`, `g`.`offset` AS `gmt_offset` FROM `view_manage` AS `vm`
 LEFT JOIN `gmt` AS `g` ON g.gmt_id = vm.gmt WHERE (view_id = 2)
0.00068497657775879
SELECT `votings`.`voting_id` AS `value`, `votings`.`voting_name` AS `text` FROM `votings` WHERE (account_id = 2) OR (system = 'Y') ORDER BY `voting_name` ASC
0.0036609172821045
SELECT `tpl`.`theme_id`, `tpl`.`theme_name`, `tpl`.`based_on`, `tpl`.`system`, CASE WHEN ((vm.style_id = tpl.copy_of_theme OR vm.style_id = tpl.theme_id) AND vm.account_id = 2) THEN 'Y' ELSE  'N' END AS `current` FROM `tpl_themes` AS `tpl`
 LEFT JOIN `view_manage` AS `vm` ON (vm.style_id = tpl.copy_of_theme OR vm.style_id = tpl.theme_id) AND vm.type = 'Hosted'  AND vm.account_id = 2 WHERE (tpl.account_id = 1 AND tpl.copy = 'N' AND tpl.system = 'Y') OR (tpl.account_id = 2 AND copy = 'N' AND tpl.system = 'N') ORDER BY `theme_name` ASC
0.00094699859619141
SELECT `votings`.* FROM `votings` WHERE (voting_id = 1)
0.00093507766723633
SELECT `voting_items`.`item_title` AS `title`, `voting_items`.`value` FROM `voting_items` WHERE (voting_id = 1) ORDER BY `value` DESC
0.0036711692810059
SELECT `view_styles`.* FROM `view_styles` WHERE (style_id = 4)
0.00091004371643066
SELECT `view_elements_styles`.`element_name` AS `name`, `view_elements_styles`.`element_type` AS `style` FROM `view_elements_styles` WHERE (style_id = 4) ORDER BY `element_name` ASC
0.0010321140289307
SELECT `languages`.`name` AS `text`, `languages`.`lang_id` AS `value` FROM `languages` WHERE (status = 'on') AND (lang != 'def') ORDER BY `lang_id` ASC
0.00091099739074707
SELECT `gmt`.* FROM `gmt` ORDER BY `offset` ASC
0.0008699893951416
SELECT `view_manage`.`view_id` AS `id`, `view_manage`.`hash`, `view_manage`.`status`, `view_manage`.`lang_id`, `view_manage`.`name` FROM `view_manage` WHERE (account_id = 2) AND (type = 'HOSTED') LIMIT 1
0.0011229515075684
SELECT `view_manage`.`view_id`, `view_manage`.`name` FROM `view_manage` WHERE (type       = 'Hosted') AND (account_id = 2)
0.00079798698425293
SELECT `view_manage`.`settings` FROM `view_manage` WHERE (view_id = 2)
0.00060582160949707
UPDATE `view_manage` SET `views_num` = views_num + 1, `last_view_date` = ? WHERE (view_id = 2)
0.00059103965759277
SELECT `faq_articles`.`faq_id` FROM `faq_articles` WHERE (code = 'AA-04668') AND (account_id = 2) AND (status = 'moderated')
0.00059199333190918
DROP TABLE IF EXISTS `tmp_visible_articles_20101`;
0.00073599815368652
DROP TABLE IF EXISTS `tmp_visible_articles_20101`;
0.00081491470336914
CREATE TEMPORARY TABLE `tmp_visible_articles_20101` (`faq_id` int PRIMARY KEY) ENGINE=MEMORY
0.09481406211853
INSERT INTO `tmp_visible_articles_20101` SELECT `faq`.`faq_id` AS `id` FROM `faq_articles` AS `faq` USE INDEX (`PRIMARY`) WHERE (account_id = 2) AND (freeAccess = 'Y') AND (draft = 'N') AND (status = 'moderated') AND ( `public` = 'Y' AND
                                ((public_start_date <= '2013-05-23 21:46:09' OR public_start_date IS NULL)
                                    AND
                                  (public_end_date IS NULL OR public_end_date >= '2013-05-23 21:46:09')
                                ))
0.0020480155944824
SELECT `tmp_visible_articles_20101`.`faq_id` FROM `tmp_visible_articles_20101`
0.045226097106934
SELECT `far`.`faq_id` AS `faqId`, `far`.`featured`, `far`.`question`, `far`.`views`, `far`.`rating`, `far`.`faq_date`, `far`.`status_change_date` FROM `faq_articles` AS `far`
 INNER JOIN `tmp_visible_articles_20101` AS `tmp` ON far.faq_id = tmp.faq_id WHERE (draft = 'N') AND (far.featured = 'Y') ORDER BY `far`.`status_change_date` DESC, `faqId` DESC LIMIT 10
0.0020668506622314
SELECT `fa`.`faq_id` AS `faqId`, `fa`.`question`, `fa`.`code`, `fa`.`views`, `fa`.`rating`, `fa`.`featured`, `fa`.`answer`, CASE
                                            WHEN (`public` = 'Y' AND (((public_start_date <= '2013-05-23 21:46:09') OR (public_start_date IS NULL))
                                                    AND (public_end_date IS NULL OR public_end_date >= '2013-05-23 21:46:09')))
                                            THEN 'Y'
                                            ELSE 'N'
                                        END  AS `public`, `fa`.`faq_date` AS `date`, `fa`.`status_change_date` AS `lastEditDate`, `fa`.`public_start_date` AS `publicStartDate` FROM `faq_articles` AS `fa` WHERE (fa.faq_id IN (4584,4814,4815,4816,4596,3565)) AND (fa.status = 'moderated') ORDER BY `fa`.`status_change_date` DESC, `faq_id` DESC
0.00066590309143066
SELECT `fc`.`cat_id`, `fc`.`cat_name`, `fc`.`account_id` FROM `articles_categories` AS `ac`
 LEFT JOIN `faq_categories` AS `fc` ON fc.cat_id = ac.category_id WHERE (ac.faq_id = 4584)
0.00049996376037598
SELECT `faq_categories`.`cat_name`, `faq_categories`.`cat_id`, `faq_categories`.`parent_id` FROM `faq_categories` WHERE (cat_id = 8)
0.0005950927734375
SELECT `faq_categories`.`cat_name`, `faq_categories`.`cat_id`, `faq_categories`.`parent_id` FROM `faq_categories` WHERE (cat_id = 17)
0.00057506561279297
SELECT `faq_categories`.`cat_name`, `faq_categories`.`cat_id`, `faq_categories`.`parent_id` FROM `faq_categories` WHERE (cat_id = 8)
0.00068092346191406
SELECT `faq_categories`.`cat_name`, `faq_categories`.`cat_id`, `faq_categories`.`parent_id` FROM `faq_categories` WHERE (cat_id = 35)
0.00075101852416992
SELECT `faq_categories`.`cat_name`, `faq_categories`.`cat_id`, `faq_categories`.`parent_id` FROM `faq_categories` WHERE (cat_id = 17)
0.00054001808166504
SELECT `faq_categories`.`cat_name`, `faq_categories`.`cat_id`, `faq_categories`.`parent_id` FROM `faq_categories` WHERE (cat_id = 37)
0.00051522254943848
SELECT `faq_categories`.`cat_name`, `faq_categories`.`cat_id`, `faq_categories`.`parent_id` FROM `faq_categories` WHERE (cat_id = 35)
0.00055813789367676
SELECT `faq_categories`.`cat_name`, `faq_categories`.`cat_id`, `faq_categories`.`parent_id` FROM `faq_categories` WHERE (cat_id = 206)
0.00054812431335449
SELECT `faq_categories`.`cat_name`, `faq_categories`.`cat_id`, `faq_categories`.`parent_id` FROM `faq_categories` WHERE (cat_id = 200)
0.00068807601928711
SELECT `faq_categories`.`cat_name`, `faq_categories`.`cat_id`, `faq_categories`.`parent_id` FROM `faq_categories` WHERE (cat_id = 221)
0.00049185752868652
SELECT `faq_categories`.`cat_name`, `faq_categories`.`cat_id`, `faq_categories`.`parent_id` FROM `faq_categories` WHERE (cat_id = 207)
0.00062394142150879
SELECT `faq_categories`.`cat_name`, `faq_categories`.`cat_id`, `faq_categories`.`parent_id` FROM `faq_categories` WHERE (cat_id = 354)
0.00042414665222168
SELECT `faq_categories`.`cat_name`, `faq_categories`.`cat_id`, `faq_categories`.`parent_id` FROM `faq_categories` WHERE (cat_id = 205)
0.00049090385437012
SELECT `faq_categories`.`cat_name`, `faq_categories`.`cat_id`, `faq_categories`.`parent_id` FROM `faq_categories` WHERE (cat_id = 355)
0.00083613395690918
SELECT `fc`.`cat_id`, `fc`.`cat_name`, `fc`.`account_id` FROM `articles_categories` AS `ac`
 LEFT JOIN `faq_categories` AS `fc` ON fc.cat_id = ac.category_id WHERE (ac.faq_id = 4814)
0.00062894821166992
SELECT `faq_categories`.`cat_name`, `faq_categories`.`cat_id`, `faq_categories`.`parent_id` FROM `faq_categories` WHERE (cat_id = 368)
0.00087785720825195
SELECT `fc`.`cat_id`, `fc`.`cat_name`, `fc`.`account_id` FROM `articles_categories` AS `ac`
 LEFT JOIN `faq_categories` AS `fc` ON fc.cat_id = ac.category_id WHERE (ac.faq_id = 4815)
0.0004878044128418
SELECT `fc`.`cat_id`, `fc`.`cat_name`, `fc`.`account_id` FROM `articles_categories` AS `ac`
 LEFT JOIN `faq_categories` AS `fc` ON fc.cat_id = ac.category_id WHERE (ac.faq_id = 4816)
0.00077009201049805
SELECT `fc`.`cat_id`, `fc`.`cat_name`, `fc`.`account_id` FROM `articles_categories` AS `ac`
 LEFT JOIN `faq_categories` AS `fc` ON fc.cat_id = ac.category_id WHERE (ac.faq_id = 4596)
0.00050497055053711
SELECT `faq_categories`.`cat_name`, `faq_categories`.`cat_id`, `faq_categories`.`parent_id` FROM `faq_categories` WHERE (cat_id = 356)
0.00055098533630371
SELECT `faq_categories`.`cat_name`, `faq_categories`.`cat_id`, `faq_categories`.`parent_id` FROM `faq_categories` WHERE (cat_id = 34)
0.00058889389038086
SELECT `fc`.`cat_id`, `fc`.`cat_name`, `fc`.`account_id` FROM `articles_categories` AS `ac`
 LEFT JOIN `faq_categories` AS `fc` ON fc.cat_id = ac.category_id WHERE (ac.faq_id = 3565)
0.00045394897460938
SELECT `faq_categories`.`cat_name`, `faq_categories`.`cat_id`, `faq_categories`.`parent_id` FROM `faq_categories` WHERE (cat_id = 284)
0.0005638599395752
SELECT `faq_categories`.`cat_name`, `faq_categories`.`cat_id`, `faq_categories`.`parent_id` FROM `faq_categories` WHERE (cat_id = 315)
0.00073790550231934
SELECT `faq_categories`.`cat_name`, `faq_categories`.`cat_id`, `faq_categories`.`parent_id` FROM `faq_categories` WHERE (cat_id = 215)
0.00064587593078613
SELECT `faq_categories`.`cat_name`, `faq_categories`.`cat_id`, `faq_categories`.`parent_id` FROM `faq_categories` WHERE (cat_id = 212)
0.049140930175781
SELECT `far`.`faq_id` AS `faqId`, `far`.`featured`, `far`.`question`, `far`.`views`, `far`.`rating`, `far`.`faq_date`, `far`.`status_change_date` FROM `faq_articles` AS `far`
 INNER JOIN `tmp_visible_articles_20101` AS `tmp` ON far.faq_id = tmp.faq_id WHERE (draft = 'N') ORDER BY `far`.`views` DESC, `faqId` DESC LIMIT 10
0.0037801265716553
SELECT `fa`.`faq_id` AS `faqId`, `fa`.`question`, `fa`.`code`, `fa`.`views`, `fa`.`rating`, `fa`.`featured`, `fa`.`answer`, CASE
                                            WHEN (`public` = 'Y' AND (((public_start_date <= '2013-05-23 21:46:09') OR (public_start_date IS NULL))
                                                    AND (public_end_date IS NULL OR public_end_date >= '2013-05-23 21:46:09')))
                                            THEN 'Y'
                                            ELSE 'N'
                                        END  AS `public`, `fa`.`faq_date` AS `date`, `fa`.`status_change_date` AS `lastEditDate`, `fa`.`public_start_date` AS `publicStartDate` FROM `faq_articles` AS `fa` WHERE (fa.faq_id IN (1064,1094,845,4584,1061,510,4614,842,698,907)) AND (fa.status = 'moderated') ORDER BY `fa`.`views` DESC, `faq_id` DESC
0.00065994262695312
SELECT `fc`.`cat_id`, `fc`.`cat_name`, `fc`.`account_id` FROM `articles_categories` AS `ac`
 LEFT JOIN `faq_categories` AS `fc` ON fc.cat_id = ac.category_id WHERE (ac.faq_id = 1064)
0.00077104568481445
SELECT `faq_categories`.`cat_name`, `faq_categories`.`cat_id`, `faq_categories`.`parent_id` FROM `faq_categories` WHERE (cat_id = 147)
0.00087308883666992
SELECT `faq_categories`.`cat_name`, `faq_categories`.`cat_id`, `faq_categories`.`parent_id` FROM `faq_categories` WHERE (cat_id = 357)
0.00073719024658203
SELECT `fc`.`cat_id`, `fc`.`cat_name`, `fc`.`account_id` FROM `articles_categories` AS `ac`
 LEFT JOIN `faq_categories` AS `fc` ON fc.cat_id = ac.category_id WHERE (ac.faq_id = 1094)
0.00059390068054199
SELECT `fc`.`cat_id`, `fc`.`cat_name`, `fc`.`account_id` FROM `articles_categories` AS `ac`
 LEFT JOIN `faq_categories` AS `fc` ON fc.cat_id = ac.category_id WHERE (ac.faq_id = 845)
0.00060892105102539
SELECT `faq_categories`.`cat_name`, `faq_categories`.`cat_id`, `faq_categories`.`parent_id` FROM `faq_categories` WHERE (cat_id = 36)
0.00064206123352051
SELECT `faq_categories`.`cat_name`, `faq_categories`.`cat_id`, `faq_categories`.`parent_id` FROM `faq_categories` WHERE (cat_id = 358)
0.0006401538848877
SELECT `fc`.`cat_id`, `fc`.`cat_name`, `fc`.`account_id` FROM `articles_categories` AS `ac`
 LEFT JOIN `faq_categories` AS `fc` ON fc.cat_id = ac.category_id WHERE (ac.faq_id = 1061)
0.0009148120880127
SELECT `fc`.`cat_id`, `fc`.`cat_name`, `fc`.`account_id` FROM `articles_categories` AS `ac`
 LEFT JOIN `faq_categories` AS `fc` ON fc.cat_id = ac.category_id WHERE (ac.faq_id = 510)
0.00047802925109863
SELECT `faq_categories`.`cat_name`, `faq_categories`.`cat_id`, `faq_categories`.`parent_id` FROM `faq_categories` WHERE (cat_id = 183)
0.00061917304992676
SELECT `faq_categories`.`cat_name`, `faq_categories`.`cat_id`, `faq_categories`.`parent_id` FROM `faq_categories` WHERE (cat_id = 182)
0.00069808959960938
SELECT `fc`.`cat_id`, `fc`.`cat_name`, `fc`.`account_id` FROM `articles_categories` AS `ac`
 LEFT JOIN `faq_categories` AS `fc` ON fc.cat_id = ac.category_id WHERE (ac.faq_id = 4614)
0.00065994262695312
SELECT `fc`.`cat_id`, `fc`.`cat_name`, `fc`.`account_id` FROM `articles_categories` AS `ac`
 LEFT JOIN `faq_categories` AS `fc` ON fc.cat_id = ac.category_id WHERE (ac.faq_id = 842)
0.00054812431335449
SELECT `fc`.`cat_id`, `fc`.`cat_name`, `fc`.`account_id` FROM `articles_categories` AS `ac`
 LEFT JOIN `faq_categories` AS `fc` ON fc.cat_id = ac.category_id WHERE (ac.faq_id = 698)
0.00047898292541504
SELECT `faq_categories`.`cat_name`, `faq_categories`.`cat_id`, `faq_categories`.`parent_id` FROM `faq_categories` WHERE (cat_id = 19)
0.00049090385437012
SELECT `faq_categories`.`cat_name`, `faq_categories`.`cat_id`, `faq_categories`.`parent_id` FROM `faq_categories` WHERE (cat_id = 9)
0.00052404403686523
SELECT `fc`.`cat_id`, `fc`.`cat_name`, `fc`.`account_id` FROM `articles_categories` AS `ac`
 LEFT JOIN `faq_categories` AS `fc` ON fc.cat_id = ac.category_id WHERE (ac.faq_id = 907)
0.00053906440734863
SELECT `faq_categories`.`cat_name`, `faq_categories`.`cat_id`, `faq_categories`.`parent_id` FROM `faq_categories` WHERE (cat_id = 142)
0.00064396858215332
SELECT `faq_categories`.`cat_name`, `faq_categories`.`cat_id`, `faq_categories`.`parent_id` FROM `faq_categories` WHERE (cat_id = 33)
0.00056600570678711
SELECT `faq_categories`.`cat_name`, `faq_categories`.`cat_id`, `faq_categories`.`parent_id` FROM `faq_categories` WHERE (cat_id = 16)
0.049200057983398
SELECT `far`.`faq_id` AS `faqId`, `far`.`featured`, `far`.`question`, `far`.`views`, `far`.`rating`, `far`.`faq_date`, `far`.`status_change_date` FROM `faq_articles` AS `far`
 INNER JOIN `tmp_visible_articles_20101` AS `tmp` ON far.faq_id = tmp.faq_id WHERE (draft = 'N') ORDER BY `far`.`rating` DESC, `faqId` DESC LIMIT 10
0.047022104263306
SELECT `fa`.`faq_id` AS `faqId`, `fa`.`question`, `fa`.`code`, `fa`.`views`, `fa`.`rating`, `fa`.`featured`, `fa`.`answer`, CASE
                                            WHEN (`public` = 'Y' AND (((public_start_date <= '2013-05-23 21:46:09') OR (public_start_date IS NULL))
                                                    AND (public_end_date IS NULL OR public_end_date >= '2013-05-23 21:46:09')))
                                            THEN 'Y'
                                            ELSE 'N'
                                        END  AS `public`, `fa`.`faq_date` AS `date`, `fa`.`status_change_date` AS `lastEditDate`, `fa`.`public_start_date` AS `publicStartDate` FROM `faq_articles` AS `fa` WHERE (fa.faq_id IN (4625,4624,4614,4610,4584,4401,994,644,642,4873)) AND (fa.status = 'moderated') ORDER BY `fa`.`rating` DESC, `faq_id` DESC
0.00073599815368652
SELECT `fc`.`cat_id`, `fc`.`cat_name`, `fc`.`account_id` FROM `articles_categories` AS `ac`
 LEFT JOIN `faq_categories` AS `fc` ON fc.cat_id = ac.category_id WHERE (ac.faq_id = 4625)
0.00077199935913086
SELECT `fc`.`cat_id`, `fc`.`cat_name`, `fc`.`account_id` FROM `articles_categories` AS `ac`
 LEFT JOIN `faq_categories` AS `fc` ON fc.cat_id = ac.category_id WHERE (ac.faq_id = 4624)
0.00069618225097656
SELECT `faq_categories`.`cat_name`, `faq_categories`.`cat_id`, `faq_categories`.`parent_id` FROM `faq_categories` WHERE (cat_id = 18)
0.00084805488586426
SELECT `faq_categories`.`cat_name`, `faq_categories`.`cat_id`, `faq_categories`.`parent_id` FROM `faq_categories` WHERE (cat_id = 47)
0.00095510482788086
SELECT `faq_categories`.`cat_name`, `faq_categories`.`cat_id`, `faq_categories`.`parent_id` FROM `faq_categories` WHERE (cat_id = 25)
0.00072693824768066
SELECT `faq_categories`.`cat_name`, `faq_categories`.`cat_id`, `faq_categories`.`parent_id` FROM `faq_categories` WHERE (cat_id = 11)
0.00055193901062012
SELECT `faq_categories`.`cat_name`, `faq_categories`.`cat_id`, `faq_categories`.`parent_id` FROM `faq_categories` WHERE (cat_id = 7)
0.00056600570678711
SELECT `faq_categories`.`cat_name`, `faq_categories`.`cat_id`, `faq_categories`.`parent_id` FROM `faq_categories` WHERE (cat_id = 66)
0.00086784362792969
SELECT `faq_categories`.`cat_name`, `faq_categories`.`cat_id`, `faq_categories`.`parent_id` FROM `faq_categories` WHERE (cat_id = 24)
0.00050902366638184
SELECT `fc`.`cat_id`, `fc`.`cat_name`, `fc`.`account_id` FROM `articles_categories` AS `ac`
 LEFT JOIN `faq_categories` AS `fc` ON fc.cat_id = ac.category_id WHERE (ac.faq_id = 4610)
0.0011088848114014
SELECT `fc`.`cat_id`, `fc`.`cat_name`, `fc`.`account_id` FROM `articles_categories` AS `ac`
 LEFT JOIN `faq_categories` AS `fc` ON fc.cat_id = ac.category_id WHERE (ac.faq_id = 4401)
0.00050806999206543
SELECT `fc`.`cat_id`, `fc`.`cat_name`, `fc`.`account_id` FROM `articles_categories` AS `ac`
 LEFT JOIN `faq_categories` AS `fc` ON fc.cat_id = ac.category_id WHERE (ac.faq_id = 994)
0.00046610832214355
SELECT `faq_categories`.`cat_name`, `faq_categories`.`cat_id`, `faq_categories`.`parent_id` FROM `faq_categories` WHERE (cat_id = 130)
0.00051188468933105
SELECT `faq_categories`.`cat_name`, `faq_categories`.`cat_id`, `faq_categories`.`parent_id` FROM `faq_categories` WHERE (cat_id = 32)
0.00069618225097656
SELECT `fc`.`cat_id`, `fc`.`cat_name`, `fc`.`account_id` FROM `articles_categories` AS `ac`
 LEFT JOIN `faq_categories` AS `fc` ON fc.cat_id = ac.category_id WHERE (ac.faq_id = 644)
0.0008080005645752
SELECT `faq_categories`.`cat_name`, `faq_categories`.`cat_id`, `faq_categories`.`parent_id` FROM `faq_categories` WHERE (cat_id = 79)
0.00055098533630371
SELECT `faq_categories`.`cat_name`, `faq_categories`.`cat_id`, `faq_categories`.`parent_id` FROM `faq_categories` WHERE (cat_id = 27)
0.00066304206848145
SELECT `faq_categories`.`cat_name`, `faq_categories`.`cat_id`, `faq_categories`.`parent_id` FROM `faq_categories` WHERE (cat_id = 12)
0.00076389312744141
SELECT `faq_categories`.`cat_name`, `faq_categories`.`cat_id`, `faq_categories`.`parent_id` FROM `faq_categories` WHERE (cat_id = 98)
0.00049614906311035
SELECT `faq_categories`.`cat_name`, `faq_categories`.`cat_id`, `faq_categories`.`parent_id` FROM `faq_categories` WHERE (cat_id = 26)
0.00052595138549805
SELECT `fc`.`cat_id`, `fc`.`cat_name`, `fc`.`account_id` FROM `articles_categories` AS `ac`
 LEFT JOIN `faq_categories` AS `fc` ON fc.cat_id = ac.category_id WHERE (ac.faq_id = 642)
0.00078392028808594
SELECT `faq_categories`.`cat_name`, `faq_categories`.`cat_id`, `faq_categories`.`parent_id` FROM `faq_categories` WHERE (cat_id = 81)
0.00080609321594238
SELECT `fc`.`cat_id`, `fc`.`cat_name`, `fc`.`account_id` FROM `articles_categories` AS `ac`
 LEFT JOIN `faq_categories` AS `fc` ON fc.cat_id = ac.category_id WHERE (ac.faq_id = 4873)
0.00059390068054199
SELECT `faq_categories`.`cat_name`, `faq_categories`.`cat_id`, `faq_categories`.`parent_id` FROM `faq_categories` WHERE (cat_id = 247)
0.00076484680175781
SELECT `faq_categories`.`cat_name`, `faq_categories`.`cat_id`, `faq_categories`.`parent_id` FROM `faq_categories` WHERE (cat_id = 246)
0.050004959106445
SELECT `far`.`faq_id` AS `faqId`, `far`.`featured`, `far`.`question`, `far`.`views`, `far`.`rating`, `far`.`faq_date`, `far`.`status_change_date` FROM `faq_articles` AS `far`
 INNER JOIN `tmp_visible_articles_20101` AS `tmp` ON far.faq_id = tmp.faq_id WHERE (draft = 'N') ORDER BY `far`.`real_creation_date` DESC, `faqId` DESC LIMIT 10
0.11342883110046
SELECT `fa`.`faq_id` AS `faqId`, `fa`.`question`, `fa`.`code`, `fa`.`views`, `fa`.`rating`, `fa`.`featured`, `fa`.`answer`, CASE
                                            WHEN (`public` = 'Y' AND (((public_start_date <= '2013-05-23 21:46:09') OR (public_start_date IS NULL))
                                                    AND (public_end_date IS NULL OR public_end_date >= '2013-05-23 21:46:09')))
                                            THEN 'Y'
                                            ELSE 'N'
                                        END  AS `public`, `fa`.`faq_date` AS `date`, `fa`.`status_change_date` AS `lastEditDate`, `fa`.`public_start_date` AS `publicStartDate` FROM `faq_articles` AS `fa` WHERE (fa.faq_id IN (4873,4872,4871,4870,4869,4865,4864,4863,4862,4861)) AND (fa.status = 'moderated') ORDER BY `fa`.`real_creation_date` DESC, `faq_id` DESC
0.00065207481384277
SELECT `fc`.`cat_id`, `fc`.`cat_name`, `fc`.`account_id` FROM `articles_categories` AS `ac`
 LEFT JOIN `faq_categories` AS `fc` ON fc.cat_id = ac.category_id WHERE (ac.faq_id = 4872)
0.00051379203796387
SELECT `fc`.`cat_id`, `fc`.`cat_name`, `fc`.`account_id` FROM `articles_categories` AS `ac`
 LEFT JOIN `faq_categories` AS `fc` ON fc.cat_id = ac.category_id WHERE (ac.faq_id = 4871)
0.00048017501831055
SELECT `faq_categories`.`cat_name`, `faq_categories`.`cat_id`, `faq_categories`.`parent_id` FROM `faq_categories` WHERE (cat_id = 371)
0.00056099891662598
SELECT `faq_categories`.`cat_name`, `faq_categories`.`cat_id`, `faq_categories`.`parent_id` FROM `faq_categories` WHERE (cat_id = 210)
0.00061607360839844
SELECT `fc`.`cat_id`, `fc`.`cat_name`, `fc`.`account_id` FROM `articles_categories` AS `ac`
 LEFT JOIN `faq_categories` AS `fc` ON fc.cat_id = ac.category_id WHERE (ac.faq_id = 4870)
0.00065493583679199
SELECT `fc`.`cat_id`, `fc`.`cat_name`, `fc`.`account_id` FROM `articles_categories` AS `ac`
 LEFT JOIN `faq_categories` AS `fc` ON fc.cat_id = ac.category_id WHERE (ac.faq_id = 4869)
0.00057196617126465
SELECT `fc`.`cat_id`, `fc`.`cat_name`, `fc`.`account_id` FROM `articles_categories` AS `ac`
 LEFT JOIN `faq_categories` AS `fc` ON fc.cat_id = ac.category_id WHERE (ac.faq_id = 4865)
0.000579833984375
SELECT `faq_categories`.`cat_name`, `faq_categories`.`cat_id`, `faq_categories`.`parent_id` FROM `faq_categories` WHERE (cat_id = 231)
0.00073480606079102
SELECT `faq_categories`.`cat_name`, `faq_categories`.`cat_id`, `faq_categories`.`parent_id` FROM `faq_categories` WHERE (cat_id = 209)
0.00050520896911621
SELECT `fc`.`cat_id`, `fc`.`cat_name`, `fc`.`account_id` FROM `articles_categories` AS `ac`
 LEFT JOIN `faq_categories` AS `fc` ON fc.cat_id = ac.category_id WHERE (ac.faq_id = 4864)
0.00068402290344238
SELECT `fc`.`cat_id`, `fc`.`cat_name`, `fc`.`account_id` FROM `articles_categories` AS `ac`
 LEFT JOIN `faq_categories` AS `fc` ON fc.cat_id = ac.category_id WHERE (ac.faq_id = 4863)
0.00052189826965332
SELECT `faq_categories`.`cat_name`, `faq_categories`.`cat_id`, `faq_categories`.`parent_id` FROM `faq_categories` WHERE (cat_id = 312)
0.0004570484161377
SELECT `faq_categories`.`cat_name`, `faq_categories`.`cat_id`, `faq_categories`.`parent_id` FROM `faq_categories` WHERE (cat_id = 310)
0.00064182281494141
SELECT `fc`.`cat_id`, `fc`.`cat_name`, `fc`.`account_id` FROM `articles_categories` AS `ac`
 LEFT JOIN `faq_categories` AS `fc` ON fc.cat_id = ac.category_id WHERE (ac.faq_id = 4862)
0.00059294700622559
SELECT `fc`.`cat_id`, `fc`.`cat_name`, `fc`.`account_id` FROM `articles_categories` AS `ac`
 LEFT JOIN `faq_categories` AS `fc` ON fc.cat_id = ac.category_id WHERE (ac.faq_id = 4861)
0.0016570091247559
SELECT `far`.`faq_id` AS `faqId`, `far`.`code`, `far`.`email`, `far`.`public` AS `public_`, `far`.`draft`, `far`.`locked`, `far`.`answer`, `far`.`lock_user_id`, `far`.`question`, `far`.`status`, `far`.`featured`, `far`.`freeAccess`, UNIX_TIMESTAMP(far.lock_date) AS `lock_date`, `far`.`author` AS `author_id`, `far`.`editor` AS `editor_id`, `far`.`faq_date` AS `date`, `far`.`rating`, `far`.`views`, `far`.`public_start_date` AS `publicStartDate_`, `far`.`public_end_date` AS `publicEndDate_`, CASE
                                                                WHEN status_change_date IS NULL OR (status_change_date <= '1970-01-01 00:00:00')
                                                                THEN faq_date
                                                                ELSE status_change_date
                                                            END  AS `lastEditDate`, CASE
                                              WHEN (`public` = 'Y' AND (((public_start_date <= '2013-05-23 21:46:09') OR (public_start_date IS NULL))
                                                    AND (public_end_date IS NULL OR public_end_date >= '2013-05-23 21:46:09')))
                                              THEN 'Y'
                                              ELSE 'N'
                                            END  AS `public`, `far`.`meta_keywords`, `far`.`meta_description`, `far`.`KEYWORD_JSGUI`, `far`.`KEYWORD_KMP`, `far`.`KEYWORD_JSGUI_URL`, `far`.`KEYWORD_KMP_URL`, CONCAT_WS(' ', us.fname,us.lname) AS `author_login`, CONCAT_WS(' ', us_e.fname,us_e.lname) AS `editor_login`, CONCAT_WS(' ', us_l.fname,us_l.lname) AS `lock_login`, (SELECT COUNT(*) FROM `faq_attachments` WHERE (faq_id = 4595)) AS `attaches` FROM `faq_articles` AS `far`
 LEFT JOIN `users` AS `us` ON far.author = us.user_id
 LEFT JOIN `users` AS `us_e` ON far.editor = us_e.user_id
 LEFT JOIN `users` AS `us_l` ON far.lock_user_id = us_l.user_id WHERE (far.faq_id = 4595) AND ( (far.`public` = 'Y' AND (((far.public_start_date <= '2013-05-23 21:46:09') OR (far.public_start_date IS NULL)) AND (far.public_end_date IS NULL OR far.public_end_date >= '2013-05-23 21:46:09')))) LIMIT 1
0.00074601173400879
SELECT `v_com`.`faq_vc_id` AS `v_com_id`, `v_com`.`visitor_subject` AS `v_com_subject`, `v_com`.`visitor_comment` AS `v_com_comment`, `v_com`.`visitor_comment_date` AS `v_com_date`, `v_com`.`nickname` AS `v_com_nick`, `v_com`.`email` AS `v_com_email`, `v_com`.`user_ip` AS `v_com_ip`, `u_com`.`faq_uc_id` AS `u_com_id`, `u_com`.`user_subject` AS `u_com_subject`, `u_com`.`user_comment` AS `u_com_comment`, `u_com`.`user_comment_date` AS `u_com_date`, CASE WHEN u_com.faq_uc_id IS NULL THEN 0 ELSE 1 END AS `nouser`, `usr`.`fname`, `usr`.`lname` FROM `faq_visitors_comments` AS `v_com`
 LEFT JOIN `faq_users_comments` AS `u_com` ON v_com.faq_vc_id = u_com.faq_vc_id
 LEFT JOIN `users` AS `usr` ON u_com.author_id = usr.user_id WHERE (v_com.faq_id = 4595) AND (v_com.comment_status != 'delete') AND (v_com.comment_status != 'new') ORDER BY `v_com_date` DESC, `u_com_date` ASC
0.00075197219848633
SELECT `faq_statistics`.`stat_id` AS `id`, `faq_statistics`.`feedback` AS `message`, `faq_statistics`.`stat_date` AS `date`, `faq_statistics`.`email`, `faq_statistics`.`rating` AS `voter` FROM `faq_statistics` WHERE (faq_id = 4595) AND (feedback NOT LIKE '')
0.00072216987609863
SELECT SQL_CALC_FOUND_ROWS `custom_fields`.`cf_id` AS `id`, `custom_fields`.`name`, `custom_fields`.`type`, `custom_fields`.`position`, `custom_fields`.`required`, `custom_fields`.`internal`, `custom_fields`.`hint`, `custom_fields`.`use_hint`, `custom_fields`.`listHeight`, `custom_fields`.`search_back`, `custom_fields`.`search_front`, `custom_fields`.`show_empty`, `custom_fields`.`WYSIWYG`, `custom_fields`.`optionsDelimiter`, `custom_fields`.`format`, `custom_fields`.`isLink` FROM `custom_fields` WHERE (account_id = 2) ORDER BY `position` ASC
0.00056290626525879
SELECT `cfa`.`cf_id`, `cfa`.`cf_o_id`, `cfa`.`value`, `cf`.`name`, `cf`.`optionsDelimiter`, `cf`.`internal`, `cf`.`type`, `cf`.`format`, `cf`.`position`, `cf`.`show_empty`, `cf`.`search_front` FROM `custom_fields_articles` AS `cfa`
 INNER JOIN `custom_fields` AS `cf` ON cf.cf_id = cfa.cf_id WHERE (cfa.faq_id = 4595) ORDER BY `cf_id` ASC
0.00049614906311035
SELECT `fc`.`cat_id`, `fc`.`cat_name`, `fc`.`account_id` FROM `articles_categories` AS `ac`
 LEFT JOIN `faq_categories` AS `fc` ON fc.cat_id = ac.category_id WHERE (ac.faq_id = 4595)
0.00055217742919922
SELECT `faq_categories`.`cat_name`, `faq_categories`.`cat_id`, `faq_categories`.`parent_id` FROM `faq_categories` WHERE (cat_id = 321)
0.00053191184997559
SELECT `faq_categories`.`cat_name`, `faq_categories`.`cat_id`, `faq_categories`.`parent_id` FROM `faq_categories` WHERE (cat_id = 222)
0.00049495697021484
SELECT `faq_categories`.`cat_name`, `faq_categories`.`cat_id`, `faq_categories`.`parent_id` FROM `faq_categories` WHERE (cat_id = 322)
0.00087308883666992
SELECT `fa`.`faq_id` AS `id`, `fa`.`views`, `fa`.`rating`, `fs`.`stat_id` AS `voters`, `fs`.`stat_date` AS `statDate` FROM `faq_articles` AS `fa`
 LEFT JOIN (SELECT `faq_statistics`.`faq_id`, MAX(stat_date) AS `stat_date`, COUNT(stat_id) AS `stat_id` FROM `faq_statistics` GROUP BY `faq_id`) AS `fs` ON fa.faq_id = fs.faq_id WHERE (fa.faq_id = 4595)
0.0008399486541748
SELECT SQL_CALC_FOUND_ROWS `us`.`user_id`, `us`.`allow_delete` AS `editable`, `us`.`type`, CASE WHEN (SELECT COUNT(user_id) FROM `users_groups` AS `ug` WHERE (ug.user_id = us.user_id)) > 0 THEN 'N' ELSE 'Y' END AS `unassigned`, `us`.`active`, `us`.`ldap_user`, `us`.`login`, `us`.`fname`, `us`.`lname`, `us`.`email`, CONCAT_WS(' ', us.fname,us.lname) AS `text` FROM `users` AS `us` WHERE (us.login != 'sales@web-site-scripts.com') AND (us.account_id = 2) AND (us.type = 'staff' AND us.active <> 'P' AND (SELECT COUNT(user_id) FROM `users_groups` AS `ug` WHERE (ug.user_id = us.user_id)) > 0) ORDER BY `login` ASC
0.00044608116149902
SELECT FOUND_ROWS()
0.00063610076904297
SELECT `fa`.`revision_id`, `fa`.`revision_date` AS `date`, CONCAT_WS(' ', us.fname,us.lname) AS `author`, CONCAT_WS(' ', us_e.fname,us_e.lname) AS `editor` FROM `faq_history` AS `fa`
 LEFT JOIN `users` AS `us` ON fa.author = us.user_id
 LEFT JOIN `users` AS `us_e` ON fa.editor = us_e.user_id WHERE (fa.faq_id = 4595) ORDER BY `date` DESC
0.00067615509033203
SELECT `faq_articles`.`freeAccess`, `faq_articles`.`account_id` FROM `faq_articles` WHERE (faq_id = 4595)
0.0016200542449951
SELECT DISTINCT `g`.`group_id`, `g`.`name`, `g`.`description`, `g`.`allow_delete` FROM `articles_categories` AS `ac`
 LEFT JOIN `groups_categories_permissions` AS `gcp` ON ac.category_id = gcp.category_id OR gcp.category_id = 0
 LEFT JOIN `groups` AS `g` ON g.group_id = gcp.group_id WHERE (ac.faq_id = 4595) AND (g.account_id = 2) ORDER BY `g`.`name` ASC
0.0062110424041748
SELECT COUNT(*) AS `num` FROM `drafts` WHERE (account_id = 2) AND (user_id = -1) AND (question NOT LIKE '' OR answer NOT LIKE '')
0.0062530040740967
SELECT `dr`.`faq_id`, `dr`.`draft_id`, `dr`.`draft_date`, `dr`.`question`, `dr`.`answer`, `fa`.`draft`, CONCAT_WS(' ', us.fname,us.lname) AS `author_login`, CONCAT_WS(' ', us_e.fname,us_e.lname) AS `editor_login` FROM `drafts` AS `dr`
 LEFT JOIN `faq_articles` AS `fa` ON dr.faq_id = fa.faq_id
 LEFT JOIN `users` AS `us` ON fa.author = us.user_id
 LEFT JOIN `users` AS `us_e` ON fa.editor = us_e.user_id WHERE (dr.faq_id = 4595) AND (dr.user_id = -1) AND ((fa.faq_date < dr.draft_date OR fa.status_change_date < dr.draft_date))
0.00085902214050293
UPDATE `faq_articles` SET `views` = ? WHERE (faq_id = 4595)
0.00090599060058594
SELECT `terms`.`term_id`, `terms`.`term`, `terms`.`term_description` AS `description` FROM `terms` WHERE (account_id = 2)
0.00066685676574707
SELECT SQL_CALC_FOUND_ROWS `faq_attachments`.`faq_attachment_id` AS `id`, `faq_attachments`.`attach_name` AS `name`, `faq_attachments`.`file_path` AS `path`, `faq_attachments`.`mime_type` AS `type`, `faq_attachments`.`file_name` FROM `faq_attachments` WHERE (faq_id = 4595) ORDER BY `name` ASC
0.00046586990356445
SELECT FOUND_ROWS()
0.00063014030456543
SELECT `g`.`group_id` AS `gid`, `g`.`name`, `g`.`allow_delete`, `g`.`description`, `g`.`type`, (SELECT COUNT(user_id) FROM `users_groups` AS `ug` WHERE (ug.group_id = g.group_id)) AS `users_count` FROM `groups` AS `g` WHERE (account_id = 2) ORDER BY `name` ASC
0.0055050849914551
SELECT `ac`.`category_id` FROM `articles_categories` AS `ac`
 INNER JOIN `tmp_visible_articles_20101` AS `tmp` ON ac.faq_id = tmp.faq_id UNION SELECT `fc`.`cat_id` AS `category_id` FROM `faq_categories` AS `fc` WHERE (fc.`public` = 'Y') AND (fc.account_id = 2)
0.014951944351196
SELECT `fc`.`cat_id` AS `id`, `fc`.`parent_id` AS `pid`, `fc`.`cat_name` AS `text`, `fc`.`position`, `fc`.`meta_keywords`, `fc`.`meta_description`, `fc`.`public`, CASE WHEN childCount.`count` IS NULL
                                                                                 THEN 0
                                                                                 ELSE childCount.`count`
                                                                             END  AS `childCount`, CASE WHEN totalArticles.`count` IS NULL
                                                                                    THEN 0
                                                                                    ELSE totalArticles.`count`
                                                                                END  AS `totalArticles` FROM `faq_categories` AS `fc`
 LEFT JOIN (SELECT `faq_categories`.`parent_id`, COUNT(cat_id) AS `count` FROM `faq_categories` GROUP BY `parent_id`) AS `childCount` ON childCount.parent_id = fc.cat_id
 LEFT JOIN (SELECT `ac`.`category_id`, COUNT(ac.faq_id) AS `count` FROM `articles_categories` AS `ac`
 INNER JOIN `tmp_visible_articles_20101` AS `tmp` ON ac.faq_id = tmp.faq_id GROUP BY `category_id`) AS `totalArticles` ON totalArticles.category_id = fc.cat_id WHERE (fc.account_id = 2) ORDER BY `fc`.`position` ASC, `fc`.`cat_name` ASC
0.00082087516784668
SELECT `gcp`.`category_id` FROM `users_groups` AS `ug`
 LEFT JOIN `groups_permissions` AS `gp` ON gp.group_id = ug.group_id
 LEFT JOIN `groups_categories_permissions` AS `gcp` ON gcp.group_id = gp.group_id WHERE (user_id = -1) AND (gp.permission = 'ActPrmCategoryCreateEdit') AND (gp.value = '1')
0.00045084953308105
SELECT `gcp`.`category_id` FROM `users_groups` AS `ug`
 LEFT JOIN `groups_permissions` AS `gp` ON gp.group_id = ug.group_id
 LEFT JOIN `groups_categories_permissions` AS `gcp` ON gcp.group_id = gp.group_id WHERE (user_id = -1) AND (gp.permission = 'ActPrmCategoryDelete') AND (gp.value = '1')
0.00061583518981934
SELECT `gcp`.`category_id` FROM `users_groups` AS `ug`
 LEFT JOIN `groups_permissions` AS `gp` ON gp.group_id = ug.group_id
 LEFT JOIN `groups_categories_permissions` AS `gcp` ON gcp.group_id = gp.group_id WHERE (user_id = -1) AND (gp.permission = 'ActPrmArticleCreateEdit') AND (gp.value = '1')
0.00073099136352539
SELECT `gcp`.`category_id` FROM `users_groups` AS `ug`
 LEFT JOIN `groups_permissions` AS `gp` ON gp.group_id = ug.group_id
 LEFT JOIN `groups_categories_permissions` AS `gcp` ON gcp.group_id = gp.group_id WHERE (user_id = -1) AND (gp.permission = 'ActPrmArticleDelete') AND (gp.value = '1')
0.0097501277923584
SELECT `fa`.`faq_id` AS `faqId`, `fa`.`question`, `fa`.`code`, `fa`.`featured`, `fa`.`rating`, `fa`.`views`, CASE
                                                     WHEN (`public` = 'Y' AND (((public_start_date <= '2013-05-23 21:46:09') OR (public_start_date IS NULL))
                                                            AND (public_end_date IS NULL OR public_end_date >= '2013-05-23 21:46:09')))
                                                     THEN 'Y'
                                                     ELSE 'N'
                                                  END  AS `public`, `fa`.`faq_date` AS `date`, `fa`.`status_change_date` AS `lastEditDate`, `ac`.`category_id` FROM `faq_articles` AS `fa`
 INNER JOIN `tmp_visible_articles_20101` AS `tmp` ON fa.faq_id = tmp.faq_id
 LEFT JOIN `articles_categories` AS `ac` ON ac.faq_id = fa.faq_id WHERE (ac.category_id IN (200,207,222,321,200,207,222,322) ) ORDER BY `fa`.`featured` ASC, `fa`.`question` asc
0.0011448860168457
SELECT `tpl_layouts`.`layout_id`, `tpl_layouts`.`template` FROM `tpl_layouts` WHERE (theme_id = 4) AND (layout_name = 'Article')
0.0013368129730225
SELECT `lb`.`block_id`, `lbc`.`block_name`, `lbc`.`template` FROM `tpl_layouts_blocks` AS `lb`
 INNER JOIN `tpl_blocks` AS `lbc` ON lbc.block_id = lb.block_id WHERE (layout_id = 59)
0.0020890235900879
SELECT `tpl_snippets`.`template`, `tpl_snippets`.`snippet_name`, `tpl_snippets`.`block_id` FROM `tpl_snippets` WHERE (theme_id = 4)
0.00076198577880859
SELECT `languages`.`lang_id` FROM `languages` WHERE (lang = 'def')
0.0072479248046875
SELECT `languages_vars`.`language_var`, `languages_vars`.`value` FROM `languages_vars` WHERE (lang_id = 1) AND (type != 'notification')
0.0077199935913086
SELECT `languages_vars`.`language_var`, `languages_vars`.`value` FROM `languages_vars` WHERE (lang_id = 2) AND (type != 'notification')
Max Query Time:Query:
0.11342883110046
SELECT `fa`.`faq_id` AS `faqId`, `fa`.`question`, `fa`.`code`, `fa`.`views`, `fa`.`rating`, `fa`.`featured`, `fa`.`answer`, CASE
                                            WHEN (`public` = 'Y' AND (((public_start_date <= '2013-05-23 21:46:09') OR (public_start_date IS NULL))
                                                    AND (public_end_date IS NULL OR public_end_date >= '2013-05-23 21:46:09')))
                                            THEN 'Y'
                                            ELSE 'N'
                                        END  AS `public`, `fa`.`faq_date` AS `date`, `fa`.`status_change_date` AS `lastEditDate`, `fa`.`public_start_date` AS `publicStartDate` FROM `faq_articles` AS `fa` WHERE (fa.faq_id IN (4873,4872,4871,4870,4869,4865,4864,4863,4862,4861)) AND (fa.status = 'moderated') ORDER BY `fa`.`real_creation_date` DESC, `faq_id` DESC
Total SQL Time:Queries Num:
0.64075684547424
161