Installing Joomla 3.2 RC with MS SQL Server 2012

This forum is for issues with installing Joomla! 3.x on IIS webservers.

Moderator: General Support Moderators

Forum rules
Forum Rules
Absolute Beginner's Guide to Joomla! <-- please read before posting, this means YOU.
Forum Post Assistant - If you are serious about wanting help, you will use this tool to help you post.
Windows Defender SmartScreen Issues <-- please read this if using Windows 10
sovainfo
Joomla! Exemplar
Joomla! Exemplar
Posts: 8808
Joined: Sat Oct 01, 2011 7:06 pm

Re: Installing Joomla 3.2 RC with MS SQL Server 2012

Post by sovainfo » Wed Dec 04, 2013 2:03 pm

Try with public $cache_handler = 'file'; in configuration.php.
Issue with migrating? Include logs/joomla_update.php in your report!
Blank screen? Verify pagesource for HTML code (javascript error)
Installation failing on populating database? Install with set_time_limit(0)
Document your customizations!

LostInEurope01
Joomla! Fledgling
Joomla! Fledgling
Posts: 3
Joined: Fri Nov 29, 2013 8:39 am
Location: Germany

Re: Installing Joomla 3.2 RC with MS SQL Server 2012

Post by LostInEurope01 » Thu Dec 05, 2013 1:16 pm

Attempting $root_user brought the same behavior for us as atvise had seen.

I am, however, under much pressure to get things running (migrate from 1.5 to 3.x) so I have dropped my attempts to use MSSQL and am successfully using MySQL 5.1.73 with J3.2 Stable and PHP5.4.22-nts under IIS7.5 on Win2008 R2 (x64). I will leave the J3.2 & MSSQL setup as is for possible testing in the future, but at the moment I have to appease my superiors, so please forgive my future absence from this thread.

@sovainfo, thanks for the vote of confidence:
hoping to see one from LostInEurope01
Should time allow, I will move forward with testing and reporting (bug tracker, guthub), but at the moment I can't - sorry. I would be curious to know if someone is looking into the changes/corrections we have proposed and how they are being received. What would be the best way of keeping tabs in your eyes?

atvise
Joomla! Apprentice
Joomla! Apprentice
Posts: 12
Joined: Thu Nov 28, 2013 10:26 am

Re: Installing Joomla 3.2 RC with MS SQL Server 2012

Post by atvise » Tue Dec 10, 2013 2:50 pm

@LostInEurope01 and @sovainfo: I have found the solution to our problem :D

Code: Select all

public function processLimit($query, $limit, $offset = 0)
{
	if ($limit == 0 && $offset == 0)
	{
		return $query;
	}

	$start = $offset;
	$end   = $offset + $limit;
	$query = preg_replace('/(SELECT\s)/i', '\1 TOP ' . $end . ' ', $query, 1);
	$query = 'WITH __actualSet AS (SELECT *, ROW_NUMBER() OVER (ORDER BY CURRENT_TIMESTAMP) AS __rowcnt FROM (' . $query;
	$query .= ') AS _tmpSet ) SELECT * FROM __actualSet WHERE [__rowcnt] > ';
	$query .= $start . ' AND [__rowcnt] <= ' . $end . ' ORDER BY [__rowcnt] ASC ';

	return $query;
}
I have looked into the fix from LostInEurope01 and debugged the sql statements when I saw that the starting offset ($start = $offset + 1;) was wrong. So I changed the code to "$start = $offset;" and everthing was working :D

Befor my change:

Code: Select all

WITH __actualSet AS (SELECT *, ROW_NUMBER() OVER (ORDER BY CURRENT_TIMESTAMP) AS __rowcnt FROM ( SELECT TOP 1 [id] FROM [#__users] WHERE [username] = 'atvise') AS _tmpSet ) SELECT * FROM __actualSet WHERE [__rowcnt] > 1 AND [__rowcnt] <= 1 ORDER BY [__rowcnt] ASC 1
After my change:

Code: Select all

WITH __actualSet AS (SELECT *, ROW_NUMBER() OVER (ORDER BY CURRENT_TIMESTAMP) AS __rowcnt FROM ( SELECT TOP 1 [id] FROM [#__users] WHERE [username] = 'atvise') AS _tmpSet ) SELECT * FROM __actualSet WHERE [__rowcnt] > 0 AND [__rowcnt] <= 1 ORDER BY [__rowcnt] ASC 1
Now a result will be generated and you are able to log in :D

Now whats left is to propose these changes to the Joomla community could someone do that ?

atvise
Joomla! Apprentice
Joomla! Apprentice
Posts: 12
Joined: Thu Nov 28, 2013 10:26 am

Re: Installing Joomla 3.2 RC with MS SQL Server 2012

Post by atvise » Wed Jan 08, 2014 12:53 pm

someone ? pretty please ?

craigreilly
Joomla! Apprentice
Joomla! Apprentice
Posts: 15
Joined: Wed Sep 17, 2008 11:25 pm

Re: Installing Joomla 3.2 RC with MS SQL Server 2012

Post by craigreilly » Thu Feb 27, 2014 5:57 pm

i'm having issues with sql 2008 r2. ARGH!

User avatar
lmckdhu
Joomla! Apprentice
Joomla! Apprentice
Posts: 7
Joined: Sun Sep 09, 2007 3:14 am
Location: Virtual World
Contact:

Re: Installing Joomla 3.2 RC with MS SQL Server 2012

Post by lmckdhu » Thu Mar 13, 2014 3:40 am

I have the same problem with joomla 3.2.3.
After I applied the fix from atvise (*)
It's up and running my website with Joomla 3.2.3 on Windows 2012 data center, MS SQL 2012 enterprise SP1, PHP 5.4.24, IIS 8.

Many Thanks,

/lmckdhu
Just Do it!
There is no way to peace & happiness. Peace & Happiness is the way.
Discover the way to peace and happiness through realizing the true nature of life and this universe.
Tu-Do is Freedom.

GeneWinstanley
Joomla! Fledgling
Joomla! Fledgling
Posts: 1
Joined: Fri Mar 21, 2014 2:56 pm

Re: Installing Joomla 3.2 RC with MS SQL Server 2012

Post by GeneWinstanley » Fri Mar 21, 2014 3:19 pm

I have been able to get 3.2.3 RC to install on IIS 7.5 with MS SQL 2008 (10.50.4000) and PHP 5.4.23 but when I try to add menu items, tags or install an extension I get a server time out. After looking at the SQL errors I see it is because a few columns (for the menu table: path, img) are null when passed to the store() method. Has anyone else run into this issue and if so is there a fix?

BTW I have Joomla 3.2.3 running on the same host with MySQL and there have been no issues. However due to a clients requirements I need to use MS SQL.

Any help is appreciated. Thanks

dtwilliams
Joomla! Fledgling
Joomla! Fledgling
Posts: 4
Joined: Thu Oct 09, 2014 4:27 pm

Re: Installing Joomla 3.2 RC with MS SQL Server 2012

Post by dtwilliams » Thu Oct 09, 2014 4:29 pm

comment out line 281 on joomla\libraries\joomla\database\query\sqlsrv.php

//$query = 'SELECT * FROM (' . $query . ') _myResults WHERE RowNumber BETWEEN ' . $start . ' AND ' . $end;

sovainfo
Joomla! Exemplar
Joomla! Exemplar
Posts: 8808
Joined: Sat Oct 01, 2011 7:06 pm

Re: Installing Joomla 3.2 RC with MS SQL Server 2012

Post by sovainfo » Thu Oct 09, 2014 6:29 pm

Issue with migrating? Include logs/joomla_update.php in your report!
Blank screen? Verify pagesource for HTML code (javascript error)
Installation failing on populating database? Install with set_time_limit(0)
Document your customizations!

dtwilliams
Joomla! Fledgling
Joomla! Fledgling
Posts: 4
Joined: Thu Oct 09, 2014 4:27 pm

Re: Installing Joomla 3.2 RC with MS SQL Server 2012

Post by dtwilliams » Fri Oct 10, 2014 9:17 am


sovainfo
Joomla! Exemplar
Joomla! Exemplar
Posts: 8808
Joined: Sat Oct 01, 2011 7:06 pm

Re: Installing Joomla 3.2 RC with MS SQL Server 2012

Post by sovainfo » Fri Oct 10, 2014 10:55 am

Would you mind letting this know on https://github.com/joomla/joomla-cms/pull/3602?
Issue with migrating? Include logs/joomla_update.php in your report!
Blank screen? Verify pagesource for HTML code (javascript error)
Installation failing on populating database? Install with set_time_limit(0)
Document your customizations!

dtwilliams
Joomla! Fledgling
Joomla! Fledgling
Posts: 4
Joined: Thu Oct 09, 2014 4:27 pm

Re: Installing Joomla 3.2 RC with MS SQL Server 2012

Post by dtwilliams » Fri Oct 10, 2014 4:27 pm

I'm getting issues with GROUP BY queries now though. Not sure if its stopping from doing anything

looks like the alias column is missing from the group array

for example,

[Microsoft][SQL Server Native Client 11.0][SQL Server]Column 'joomla_menu.alias' is invalid in the select list because it is not contained in either an aggregate function or the GROUP BY clause.SQL=SELECT a.id AS value, a.title AS text, a.alias, a.level, a.menutype, a.type, a.template_style_id, a.checked_out FROM joomla_menu AS a LEFT JOIN [joomla_menu] AS b ON a.lft > b.lft AND a.rgt < b.rgt WHERE a.published != -2 GROUP BY a.id, a.title, a.level, a.menutype, a.type, a.template_style_id, a.checked_out, a.lft ORDER BY a.lft ASC

sovainfo
Joomla! Exemplar
Joomla! Exemplar
Posts: 8808
Joined: Sat Oct 01, 2011 7:06 pm

Re: Installing Joomla 3.2 RC with MS SQL Server 2012

Post by sovainfo » Fri Oct 10, 2014 5:49 pm

Replace line 64 of administrator/components/com_menus/models/fields/menuparent.php

Code: Select all

->group('a.id, a.title, a.alias, a.level, a.lft, a.rgt, a.menutype, a.parent_id, a.published')
And line 177 of com_menus/helpers/menus.php.
Issue with migrating? Include logs/joomla_update.php in your report!
Blank screen? Verify pagesource for HTML code (javascript error)
Installation failing on populating database? Install with set_time_limit(0)
Document your customizations!

dtwilliams
Joomla! Fledgling
Joomla! Fledgling
Posts: 4
Joined: Thu Oct 09, 2014 4:27 pm

Re: Installing Joomla 3.2 RC with MS SQL Server 2012

Post by dtwilliams » Mon Oct 13, 2014 11:20 am

yes that worked

I'm getting issues trying to create a new menu item now

ERR_EMPTY_RESPONSE


Locked

Return to “Joomla! 3.x on IIS webserver”