Re: Cake 2.5.1 Extremely Slow With MSSQL?

2014-08-15 Thread abhijit kakade
I have simmilar setup linux webserver cakephp 2 and mssql, never seen a
performance issue. Only issue is if you tried to connect remote sql server
from local.. It works perfectly fine when both apache and sql are on
internet. For connectivity Im using pear dblib.

Thanks
Abhijit
On 15 Aug 2014 20:05, "Alan Read"  wrote:

> In my case, The decision to use a Linux Web Server and SQL Server was
> already made and implemented before I arrived. To make matters worse we are
> still stuck on cakephp 1.3 using the mssql driver :(. The whole reason I
> ran into the Cursor issue was because I am almost done developing a MS ODBC
> Cakephp Datasource (for 2.x) using Microsoft ODBC Driver 11 for Sql Server
> on Linux (http://msdn.microsoft.com/en-us/library/hh568451(v=sql.110).aspx)
> and unixODBC.
>
>
> On Fri, Aug 15, 2014 at 4:59 AM, Борислав Събев Borislav Sabev <
> borislavsa...@gmail.com> wrote:
>
>> I've been following this theme for quite some time now and I need to ask:
>>
>> Why would anyone want to use MSSQL with PHP?
>>
>> And before anyone starts getting evangelist on me:
>> Yes, MSSQL could be considered an advantage over MySQL and it is. Sure!
>> But IT IS NOT THE ONLY OPTION and it is very,very poorly supported if your
>> application is hosted on Unix/Linux.
>> Historically, PHP was made to work in the Unix/Linux environment and then 
>> *ported
>> to MS Win/IIS*. We all know that Microsoft loves to hate the Penguin.
>> Has anyone used the FreeTDS driver on Linux? I sure have and not by my
>> own choice. It does not support transactions... Yes! Transactions!!
>>
>> Why does Microsoft NOT produce a good driver for their DB but for
>> Linux/Unix?
>> Why would you want to pay Microsoft's fees if they don't really support
>> you?
>> Why would you want to run your code with the disadvantages that hosting
>> it on MS IIS and still pay them?
>>
>> The bottom line is: *Microsoft wants to sell their shit* *and for loads
>> of cash*.
>> They will do this at any cost and the first thing they do is to push us
>> all back in the corner - that's why there is no official Unix/Linux driver
>> for MSSQL. Because they want us to host our shit on their shitty OS and
>> most importantly *NOT BE ABLE TO HAVE THE CHOICE*.
>>
>> Sure, I am an Open Source advocate and you can say I am biased. But I can
>> argue that it is much better for one to be able to have a multitude of
>> choices that to be given with only one and no laternatives.
>> That's the problem, ain't it?
>>
>> So for me, bottom line is if you want a real RDBMS as of  Edgar Codd's
>> RDB theory (and no not MySQL) you still have PGSQL and it goes even further
>> than that.
>> PostgreSQL gives us what MySQL (I think) will never be able to and takes
>> so many steps forward. Even from MSSQL.
>>
>> A lot of people take the decision to use MSSQL because "that's what
>> they've used previously" but this does not make it the right choice.
>> Sure, you may not have a choice now but what about in the future?
>> So please, think about it and don't get evangelist on me. :)
>>
>> Best Regards,
>> Borislav Sabev.
>>
>>
>>
>> On Thursday, 29 May 2014 00:19:09 UTC+3, Jordan Hopfner wrote:
>>>
>>> Hey guys,
>>>
>>> I'm using the latest version of Cake (2.5.1) and am having a problem
>>> with extremely slow connections to a MSSQL server. A controller action that
>>> only has one simple select statement is taking an upwards of 50 seconds to
>>> complete. I don't think it's the select statement itself, I have a created
>>> an empty page that connects to MSSQL via PDO and executes the exact same
>>> statement and the result is instantaneous, so this leads me to believe it's
>>> a problem with the MSSQL data source packaged with Cake. If it was a driver
>>> or connection issue I would assume it would happen on the test page as
>>> well. Any ideas? I'm on PHP 5.3.x and am connecting to SQL Server 2008 R2.
>>>
>>> Jordan
>>>
>>  --
>> Like Us on FaceBook https://www.facebook.com/CakePHP
>> Find us on Twitter http://twitter.com/CakePHP
>>
>> ---
>> You received this message because you are subscribed to a topic in the
>> Google Groups "CakePHP" group.
>> To unsubscribe from this topic, visit
>> https://groups.google.com/d/topic/cake-php/2Vqixc1UGCw/unsubscribe.
>>  To unsubscribe from this group and all its topics, send an email to
>> cake-php+unsubscr...@googlegroups.com.
>> To post to this group, send email to cake-php@googlegroups.com.
>> Visit this group at http://groups.google.com/group/cake-php.
>> For more options, visit https://groups.google.com/d/optout.
>>
>
>
>
> --
> Alan Read
>
> --
> Like Us on FaceBook https://www.facebook.com/CakePHP
> Find us on Twitter http://twitter.com/CakePHP
>
> ---
> You received this message because you are subscribed to the Google Groups
> "CakePHP" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to cake-php+unsubscr...@googlegroups.com.
> To post to this group, send email to cake-php@googlegroups.c

Re: Cake 2.5.1 Extremely Slow With MSSQL?

2014-08-15 Thread Alan Read
In my case, The decision to use a Linux Web Server and SQL Server was
already made and implemented before I arrived. To make matters worse we are
still stuck on cakephp 1.3 using the mssql driver :(. The whole reason I
ran into the Cursor issue was because I am almost done developing a MS ODBC
Cakephp Datasource (for 2.x) using Microsoft ODBC Driver 11 for Sql Server
on Linux (http://msdn.microsoft.com/en-us/library/hh568451(v=sql.110).aspx)
and unixODBC.


On Fri, Aug 15, 2014 at 4:59 AM, Борислав Събев Borislav Sabev <
borislavsa...@gmail.com> wrote:

> I've been following this theme for quite some time now and I need to ask:
>
> Why would anyone want to use MSSQL with PHP?
>
> And before anyone starts getting evangelist on me:
> Yes, MSSQL could be considered an advantage over MySQL and it is. Sure!
> But IT IS NOT THE ONLY OPTION and it is very,very poorly supported if your
> application is hosted on Unix/Linux.
> Historically, PHP was made to work in the Unix/Linux environment and then 
> *ported
> to MS Win/IIS*. We all know that Microsoft loves to hate the Penguin.
> Has anyone used the FreeTDS driver on Linux? I sure have and not by my own
> choice. It does not support transactions... Yes! Transactions!!
>
> Why does Microsoft NOT produce a good driver for their DB but for
> Linux/Unix?
> Why would you want to pay Microsoft's fees if they don't really support
> you?
> Why would you want to run your code with the disadvantages that hosting it
> on MS IIS and still pay them?
>
> The bottom line is: *Microsoft wants to sell their shit* *and for loads
> of cash*.
> They will do this at any cost and the first thing they do is to push us
> all back in the corner - that's why there is no official Unix/Linux driver
> for MSSQL. Because they want us to host our shit on their shitty OS and
> most importantly *NOT BE ABLE TO HAVE THE CHOICE*.
>
> Sure, I am an Open Source advocate and you can say I am biased. But I can
> argue that it is much better for one to be able to have a multitude of
> choices that to be given with only one and no laternatives.
> That's the problem, ain't it?
>
> So for me, bottom line is if you want a real RDBMS as of  Edgar Codd's RDB
> theory (and no not MySQL) you still have PGSQL and it goes even further
> than that.
> PostgreSQL gives us what MySQL (I think) will never be able to and takes
> so many steps forward. Even from MSSQL.
>
> A lot of people take the decision to use MSSQL because "that's what
> they've used previously" but this does not make it the right choice.
> Sure, you may not have a choice now but what about in the future?
> So please, think about it and don't get evangelist on me. :)
>
> Best Regards,
> Borislav Sabev.
>
>
>
> On Thursday, 29 May 2014 00:19:09 UTC+3, Jordan Hopfner wrote:
>>
>> Hey guys,
>>
>> I'm using the latest version of Cake (2.5.1) and am having a problem with
>> extremely slow connections to a MSSQL server. A controller action that only
>> has one simple select statement is taking an upwards of 50 seconds to
>> complete. I don't think it's the select statement itself, I have a created
>> an empty page that connects to MSSQL via PDO and executes the exact same
>> statement and the result is instantaneous, so this leads me to believe it's
>> a problem with the MSSQL data source packaged with Cake. If it was a driver
>> or connection issue I would assume it would happen on the test page as
>> well. Any ideas? I'm on PHP 5.3.x and am connecting to SQL Server 2008 R2.
>>
>> Jordan
>>
>  --
> Like Us on FaceBook https://www.facebook.com/CakePHP
> Find us on Twitter http://twitter.com/CakePHP
>
> ---
> You received this message because you are subscribed to a topic in the
> Google Groups "CakePHP" group.
> To unsubscribe from this topic, visit
> https://groups.google.com/d/topic/cake-php/2Vqixc1UGCw/unsubscribe.
> To unsubscribe from this group and all its topics, send an email to
> cake-php+unsubscr...@googlegroups.com.
> To post to this group, send email to cake-php@googlegroups.com.
> Visit this group at http://groups.google.com/group/cake-php.
> For more options, visit https://groups.google.com/d/optout.
>



-- 
Alan Read

-- 
Like Us on FaceBook https://www.facebook.com/CakePHP
Find us on Twitter http://twitter.com/CakePHP

--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
To post to this group, send email to cake-php@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/d/optout.


Re: Cake 2.5.1 Extremely Slow With MSSQL?

2014-08-15 Thread Alan Read
Hi Dakota,

Thanks for clearing that up! I haven't looked at the source for CakePHP 3
yet so I didn't actually see how they implemented it. I should do more
research next time as I don't want to mislead anybody...


On Fri, Aug 15, 2014 at 3:32 AM, Dakota  wrote:

> Hi Alan,
>
> The Query object does not use SQL cursors, but rather buffers the results
> locally (In PHP land) and builds lists from that.
>
> However, CakePHP 3.0 does rely on obtaining the row count (With
> PDOStatement::rowCount), which return -1 with PDO::CURSOR_FWDONLY (
> http://technet.microsoft.com/en-us/library/ff628154(v=sql.105).aspx)
>
>
> On Thursday, 14 August 2014 20:00:52 UTC+2, Alan Read wrote:
>
>> I think the reasoning to use scroll was for future reasonsin CakePHP
>> 3 they are introducing a new ORM layer (http://book.cakephp.org/3.0/
>> en/appendices/orm-migration.html) and a Query Object. I believe they are
>> going to implement the Query Object with methods like last, first,
>> previous, next etc. With a scrollable cursor those operations are mapped
>> one to one and should be pretty fast:
>>
>>
>>- *SCROLL: *It specifies that all fetch options (FIRST, LAST, PRIOR,
>>NEXT, RELATIVE, ABSOLUTE) are available. If SCROLL is not specified in an
>>ISO DECLARE CURSOR, NEXT is the only fetch option supported. SCROLL cannot
>>be specified if FAST_FORWARD is also specified.
>>
>> (http://www.sqlservergeeks.com/articles/sql-server-bi/31/
>> sql-server-what-is-a-cursor)
>>
>> If the cursor is set to FWDONLY, then the only operation available would
>> be next. In my case, with cursor set to SCROLL a simple find query was
>> taking 18 seconds to complete...since the majority of the time I just
>> forward loop through a result set, losing first, last, previous etc is not
>> that big of an issue.
>>
>>
>>
>>
>> On Thu, Aug 14, 2014 at 11:31 AM, Jordan Hopfner 
>> wrote:
>>
>>> In the PHP manual it states:
>>>
>>> PDO::CURSOR_FWDONLY (integer
>>> ) Create a
>>> PDOStatement  object
>>> with a forward-only cursor. This is the default cursor choice, as it is the
>>> fastest and most common data access pattern in PHP.
>>> So I don't think it's a bad idea, but I don't know the reasoning the
>>> reasoning for using SCROLL over FWDONLY.
>>>
>>> On Thursday, August 14, 2014 6:38:47 AM UTC-6, ravag...@gmail.com wrote:

 I'm not sure if this is really a good idea.
 See:
 http://stackoverflow.com/questions/1155211/what-is-pdo-scrol
 lable-cursor

 But if you want this find its way into the core, then you can help the
 core team to get in there.

 Help yourself by either:
 a) Create an issue explaining everything on GitHub
 https://github.com/cakephp/cakephp/issues/new
 b) Fork the code, change it, prove that it really solves the problem
 without breaking anything else and create a Pull Request
 https://github.com/cakephp/cakephp/

 Thanks
 Marc

 Am Mittwoch, 13. August 2014 16:07:26 UTC+2 schrieb Jordan Hopfner:
>
> Thanks Alan, appreciate the help. The project has been put on hold for
> now but I'll definitely try this change when I go to use SQL Server again.
> It would be great if the core team would make these changes to Cake :)
>
> On Friday, August 8, 2014 10:30:20 PM UTC-6, Alan Read wrote:
>>
>> Changing the line:
>>
>> 772) $prepareOptions += array(PDO::ATTR_CURSOR => PDO::CURSOR_SCROLL
>> );
>>
>> to
>>
>> 772) $prepareOptions += array(PDO::ATTR_CURSOR => PDO::
>> *CURSOR_FWDONLY*);
>>
>> in the _execute function inside of Sqlserver.php solved this issue
>> for me
>>
>> On Wednesday, May 28, 2014 5:19:09 PM UTC-4, Jordan Hopfner wrote:
>>>
>>> Hey guys,
>>>
>>> I'm using the latest version of Cake (2.5.1) and am having a problem
>>> with extremely slow connections to a MSSQL server. A controller action 
>>> that
>>> only has one simple select statement is taking an upwards of 50 seconds 
>>> to
>>> complete. I don't think it's the select statement itself, I have a 
>>> created
>>> an empty page that connects to MSSQL via PDO and executes the exact same
>>> statement and the result is instantaneous, so this leads me to believe 
>>> it's
>>> a problem with the MSSQL data source packaged with Cake. If it was a 
>>> driver
>>> or connection issue I would assume it would happen on the test page as
>>> well. Any ideas? I'm on PHP 5.3.x and am connecting to SQL Server 2008 
>>> R2.
>>>
>>> Jordan
>>>
>>  --
>>> Like Us on FaceBook https://www.facebook.com/CakePHP
>>> Find us on Twitter http://twitter.com/CakePHP
>>>
>>> ---
>>> You received this message because you are subscribed to a topic in the
>>> Google Groups "CakePHP" group.
>>> To unsubscribe from this topic, visit http

Re: Cake 2.5.1 Extremely Slow With MSSQL?

2014-08-15 Thread Dakota
We usually a exclusive *nix environment.

But, we've got two simple reasons as to our choice in SQLServer in the 
current project:

   1. The client requested it. Their existing infrastructure, as well as 
   all their existing systems run in a MS environment. They are not willing, 
   nor can they afford to switch over, or run two separate environments
   2. FileStream.

Microsoft of today is a different beast than Microsoft of a few years ago. 
PHP is now a first class citizen on MS environments and works incredibly 
well under IIS.

The simple fact in our (as in the company I work for) reason for SQLServer 
is it's what the client is paying for. If they client wishes to pay for 
SQLServer, then so be it. 

On Friday, 15 August 2014 10:59:20 UTC+2, Борислав Събев Borislav Sabev 
wrote:
>
> I've been following this theme for quite some time now and I need to ask:
>
> Why would anyone want to use MSSQL with PHP? 
>
> And before anyone starts getting evangelist on me:
> Yes, MSSQL could be considered an advantage over MySQL and it is. Sure! 
> But IT IS NOT THE ONLY OPTION and it is very,very poorly supported if your 
> application is hosted on Unix/Linux. 
> Historically, PHP was made to work in the Unix/Linux environment and then 
> *ported 
> to MS Win/IIS*. We all know that Microsoft loves to hate the Penguin.
> Has anyone used the FreeTDS driver on Linux? I sure have and not by my own 
> choice. It does not support transactions... Yes! Transactions!!
>
> Why does Microsoft NOT produce a good driver for their DB but for 
> Linux/Unix?
> Why would you want to pay Microsoft's fees if they don't really support 
> you? 
> Why would you want to run your code with the disadvantages that hosting it 
> on MS IIS and still pay them?
>
> The bottom line is: *Microsoft wants to sell their shit* *and for loads 
> of cash*. 
> They will do this at any cost and the first thing they do is to push us 
> all back in the corner - that's why there is no official Unix/Linux driver 
> for MSSQL. Because they want us to host our shit on their shitty OS and 
> most importantly *NOT BE ABLE TO HAVE THE CHOICE*.
>
> Sure, I am an Open Source advocate and you can say I am biased. But I can 
> argue that it is much better for one to be able to have a multitude of 
> choices that to be given with only one and no laternatives.
> That's the problem, ain't it?
>
> So for me, bottom line is if you want a real RDBMS as of  Edgar Codd's RDB 
> theory (and no not MySQL) you still have PGSQL and it goes even further 
> than that.
> PostgreSQL gives us what MySQL (I think) will never be able to and takes 
> so many steps forward. Even from MSSQL. 
>
> A lot of people take the decision to use MSSQL because "that's what 
> they've used previously" but this does not make it the right choice.
> Sure, you may not have a choice now but what about in the future?
> So please, think about it and don't get evangelist on me. :)
>
> Best Regards,
> Borislav Sabev.
>
>
> On Thursday, 29 May 2014 00:19:09 UTC+3, Jordan Hopfner wrote:
>>
>> Hey guys,
>>
>> I'm using the latest version of Cake (2.5.1) and am having a problem with 
>> extremely slow connections to a MSSQL server. A controller action that only 
>> has one simple select statement is taking an upwards of 50 seconds to 
>> complete. I don't think it's the select statement itself, I have a created 
>> an empty page that connects to MSSQL via PDO and executes the exact same 
>> statement and the result is instantaneous, so this leads me to believe it's 
>> a problem with the MSSQL data source packaged with Cake. If it was a driver 
>> or connection issue I would assume it would happen on the test page as 
>> well. Any ideas? I'm on PHP 5.3.x and am connecting to SQL Server 2008 R2.
>>
>> Jordan
>>
>

-- 
Like Us on FaceBook https://www.facebook.com/CakePHP
Find us on Twitter http://twitter.com/CakePHP

--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
To post to this group, send email to cake-php@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/d/optout.


Re: Post idea: Long term, large scales projects with CakePHP

2014-08-15 Thread David Yell
It would have been super helpful to include the link to the repo, d'oh

https://github.com/davidyell/BakeYourDreams

-- 
Like Us on FaceBook https://www.facebook.com/CakePHP
Find us on Twitter http://twitter.com/CakePHP

--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
To post to this group, send email to cake-php@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/d/optout.


Re: Post idea: Long term, large scales projects with CakePHP

2014-08-15 Thread David Yell
So I have created the repo and put some placeholder files in there, with a 
bit of copy. If I need to write about the software patterns I will need to 
learn the core and learn about software patterns, so that one might take a 
while. I'll work on the tips and tricks mostly, as long as I can remember 
all the clever stuff I've been told.

I would welcome contributions, so please feel free to fork and PR your 
thoughts, ideas and such.

Hopefully once it's up to par we can look at incorporating it into the 
book, or into a page 'About the framework' or similar on the website

-- 
Like Us on FaceBook https://www.facebook.com/CakePHP
Find us on Twitter http://twitter.com/CakePHP

--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
To post to this group, send email to cake-php@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/d/optout.


Re: Post idea: Long term, large scales projects with CakePHP

2014-08-15 Thread David Yell
The reason I included the bit about the 'core developer' was because they
would have the best understanding of how the core components work and which
software design principles they encompass.

I do agree that we can all do something to help market the framework, but
marketing needs to come from an 'official' channel. Sure it could be a book
page created collaboratively by the community, which I think would help
rather than a blog post. Hence why I decided to post on groups rather than
just try and write up a post myself.

I'd certainly be happy to get something started. Perhaps I should start a
repo on GH with a markdown document? I've been invited to speak about
CakePHP at a local usergroup so this would be ideal preparation.

I'm not too sure on the topics which should be covered though, short of the
software design principles. An example from the last talk was the
separation of concerns and that models shouldn't know how to save their
data, and model data should be just data. Perhaps some of the topics could
just revolve around user-contributed tips and tricks? Such as good caching,
routing tweaks and any other tweaks.


On 15 August 2014 10:31, José Lorenzo  wrote:

> I really like the idea David, CakePHP definitely needs more and better
> marketing. What I disagree with is that only a core developer or something
> with a lot of experience can write such articles or help promoting the
> framework, anyone could start adding their experiences with CakePHP, even
> just to say "It made my day a bit easier".
>
> What would you propose to encourage more people contributing that kind of
> feedback? Would you be willing to write an article we can expose as a case
> study?
>
>
> On Thursday, August 14, 2014 4:58:55 PM UTC+2, David Yell wrote:
>>
>> *TL;DR*, Tell people why and how a RAD framework can compete with the
>> likes of Symfony for larger projects which have a long lifetime.
>>
>> As we all know CakePHP get's a pretty bad rep in the PHP community and no
>> more so than from the Symfony corner. They love to belittle the framework
>> and regurgitate Uncle Bob. It would be nice to have a bit of a slap-down
>> post about using a RAD framework can be for more than just prototyping.
>>
>> It would be great for someone with good knowledge of the core to detail
>> some of the software design principles being used in the framework and how
>> you can build large scale commercial and stable applications using CakePHP.
>> So often people look down on CakePHP because they see it as being "magic",
>> "tightly coupled" or "slow". Yeah, we've all heard them spouting this
>> garbage. So why not address it?
>>
>> I think a post or even a book page which extols the virtues of the
>> framework would be beneficial. Something which advertises the framework,
>> why it's cool, what it does which is cool. I know there are some large
>> scale sites out there using the framework. I know I've built a few which *I'd
>> consider* reasonably high traffic (eg, 80k unique visitors a month). So
>> it can be done.
>>
>> I also know that there are plugins, tips, hints and optimisations out
>> there which people have done to help their app. Streamlining the framework
>> by removing all the default routes for example. Making better use of
>> caching. Whatever it might be I would really like to see some Laravel style
>> marketing happening for CakePHP because it is a good framework.
>>
>> I'd welcome other peoples thoughts and suggestions.
>>
>  --
> Like Us on FaceBook https://www.facebook.com/CakePHP
> Find us on Twitter http://twitter.com/CakePHP
>
> ---
> You received this message because you are subscribed to a topic in the
> Google Groups "CakePHP" group.
> To unsubscribe from this topic, visit
> https://groups.google.com/d/topic/cake-php/XtbhyWkl-l8/unsubscribe.
> To unsubscribe from this group and all its topics, send an email to
> cake-php+unsubscr...@googlegroups.com.
> To post to this group, send email to cake-php@googlegroups.com.
> Visit this group at http://groups.google.com/group/cake-php.
> For more options, visit https://groups.google.com/d/optout.
>

-- 
Like Us on FaceBook https://www.facebook.com/CakePHP
Find us on Twitter http://twitter.com/CakePHP

--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
To post to this group, send email to cake-php@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/d/optout.


Re: Post idea: Long term, large scales projects with CakePHP

2014-08-15 Thread Stephen S
I'd love to contribute to this also if you wish, so just a little about my
experience, I first started using 1.x roughly back in 2006/2007 and the
majority of my projects since have been created in CakePHP. I've used other
frameworks in between but I have a lot of things to say in favour of
CakePHP as my personal preference.

I'm currently working on a complete remake of a popular music distribution
website with my colleague in CakePHP 2.4.x, due to go live shortly (3041
commits and going =]).

One side note about past 'debates' which niggled at me a little concerning
which framework is better (I know this probably isn't the case here), the
benchmarks done out of the box don't represent my end product with CakePHP,
I have plenty of control over how to influence the speed of my project, so
I have found these benchmarks to be less useful than others may.


On 15 August 2014 10:31, José Lorenzo  wrote:

> I really like the idea David, CakePHP definitely needs more and better
> marketing. What I disagree with is that only a core developer or something
> with a lot of experience can write such articles or help promoting the
> framework, anyone could start adding their experiences with CakePHP, even
> just to say "It made my day a bit easier".
>
> What would you propose to encourage more people contributing that kind of
> feedback? Would you be willing to write an article we can expose as a case
> study?
>
>
> On Thursday, August 14, 2014 4:58:55 PM UTC+2, David Yell wrote:
>>
>> *TL;DR*, Tell people why and how a RAD framework can compete with the
>> likes of Symfony for larger projects which have a long lifetime.
>>
>> As we all know CakePHP get's a pretty bad rep in the PHP community and no
>> more so than from the Symfony corner. They love to belittle the framework
>> and regurgitate Uncle Bob. It would be nice to have a bit of a slap-down
>> post about using a RAD framework can be for more than just prototyping.
>>
>> It would be great for someone with good knowledge of the core to detail
>> some of the software design principles being used in the framework and how
>> you can build large scale commercial and stable applications using CakePHP.
>> So often people look down on CakePHP because they see it as being "magic",
>> "tightly coupled" or "slow". Yeah, we've all heard them spouting this
>> garbage. So why not address it?
>>
>> I think a post or even a book page which extols the virtues of the
>> framework would be beneficial. Something which advertises the framework,
>> why it's cool, what it does which is cool. I know there are some large
>> scale sites out there using the framework. I know I've built a few which *I'd
>> consider* reasonably high traffic (eg, 80k unique visitors a month). So
>> it can be done.
>>
>> I also know that there are plugins, tips, hints and optimisations out
>> there which people have done to help their app. Streamlining the framework
>> by removing all the default routes for example. Making better use of
>> caching. Whatever it might be I would really like to see some Laravel style
>> marketing happening for CakePHP because it is a good framework.
>>
>> I'd welcome other peoples thoughts and suggestions.
>>
>  --
> Like Us on FaceBook https://www.facebook.com/CakePHP
> Find us on Twitter http://twitter.com/CakePHP
>
> ---
> You received this message because you are subscribed to the Google Groups
> "CakePHP" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to cake-php+unsubscr...@googlegroups.com.
> To post to this group, send email to cake-php@googlegroups.com.
> Visit this group at http://groups.google.com/group/cake-php.
> For more options, visit https://groups.google.com/d/optout.
>



-- 
Kind Regards
 Stephen Speakman

-- 
Like Us on FaceBook https://www.facebook.com/CakePHP
Find us on Twitter http://twitter.com/CakePHP

--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
To post to this group, send email to cake-php@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/d/optout.


Re: Post idea: Long term, large scales projects with CakePHP

2014-08-15 Thread José Lorenzo
I really like the idea David, CakePHP definitely needs more and better 
marketing. What I disagree with is that only a core developer or something 
with a lot of experience can write such articles or help promoting the 
framework, anyone could start adding their experiences with CakePHP, even 
just to say "It made my day a bit easier".

What would you propose to encourage more people contributing that kind of 
feedback? Would you be willing to write an article we can expose as a case 
study?

On Thursday, August 14, 2014 4:58:55 PM UTC+2, David Yell wrote:
>
> *TL;DR*, Tell people why and how a RAD framework can compete with the 
> likes of Symfony for larger projects which have a long lifetime.
>
> As we all know CakePHP get's a pretty bad rep in the PHP community and no 
> more so than from the Symfony corner. They love to belittle the framework 
> and regurgitate Uncle Bob. It would be nice to have a bit of a slap-down 
> post about using a RAD framework can be for more than just prototyping.
>
> It would be great for someone with good knowledge of the core to detail 
> some of the software design principles being used in the framework and how 
> you can build large scale commercial and stable applications using CakePHP. 
> So often people look down on CakePHP because they see it as being "magic", 
> "tightly coupled" or "slow". Yeah, we've all heard them spouting this 
> garbage. So why not address it?
>
> I think a post or even a book page which extols the virtues of the 
> framework would be beneficial. Something which advertises the framework, 
> why it's cool, what it does which is cool. I know there are some large 
> scale sites out there using the framework. I know I've built a few which *I'd 
> consider* reasonably high traffic (eg, 80k unique visitors a month). So 
> it can be done.
>
> I also know that there are plugins, tips, hints and optimisations out 
> there which people have done to help their app. Streamlining the framework 
> by removing all the default routes for example. Making better use of 
> caching. Whatever it might be I would really like to see some Laravel style 
> marketing happening for CakePHP because it is a good framework.
>
> I'd welcome other peoples thoughts and suggestions.
>

-- 
Like Us on FaceBook https://www.facebook.com/CakePHP
Find us on Twitter http://twitter.com/CakePHP

--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
To post to this group, send email to cake-php@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/d/optout.


Re: Cake 2.5.1 Extremely Slow With MSSQL?

2014-08-15 Thread Борислав Събев Borislav Sabev
I've been following this theme for quite some time now and I need to ask:

Why would anyone want to use MSSQL with PHP? 

And before anyone starts getting evangelist on me:
Yes, MSSQL could be considered an advantage over MySQL and it is. Sure! But 
IT IS NOT THE ONLY OPTION and it is very,very poorly supported if your 
application is hosted on Unix/Linux. 
Historically, PHP was made to work in the Unix/Linux environment and then 
*ported 
to MS Win/IIS*. We all know that Microsoft loves to hate the Penguin.
Has anyone used the FreeTDS driver on Linux? I sure have and not by my own 
choice. It does not support transactions... Yes! Transactions!!

Why does Microsoft NOT produce a good driver for their DB but for 
Linux/Unix?
Why would you want to pay Microsoft's fees if they don't really support 
you? 
Why would you want to run your code with the disadvantages that hosting it 
on MS IIS and still pay them?

The bottom line is: *Microsoft wants to sell their shit* *and for loads of 
cash*. 
They will do this at any cost and the first thing they do is to push us all 
back in the corner - that's why there is no official Unix/Linux driver for 
MSSQL. Because they want us to host our shit on their shitty OS and most 
importantly *NOT BE ABLE TO HAVE THE CHOICE*.

Sure, I am an Open Source advocate and you can say I am biased. But I can 
argue that it is much better for one to be able to have a multitude of 
choices that to be given with only one and no laternatives.
That's the problem, ain't it?

So for me, bottom line is if you want a real RDBMS as of  Edgar Codd's RDB 
theory (and no not MySQL) you still have PGSQL and it goes even further 
than that.
PostgreSQL gives us what MySQL (I think) will never be able to and takes so 
many steps forward. Even from MSSQL. 

A lot of people take the decision to use MSSQL because "that's what they've 
used previously" but this does not make it the right choice.
Sure, you may not have a choice now but what about in the future?
So please, think about it and don't get evangelist on me. :)

Best Regards,
Borislav Sabev.


On Thursday, 29 May 2014 00:19:09 UTC+3, Jordan Hopfner wrote:
>
> Hey guys,
>
> I'm using the latest version of Cake (2.5.1) and am having a problem with 
> extremely slow connections to a MSSQL server. A controller action that only 
> has one simple select statement is taking an upwards of 50 seconds to 
> complete. I don't think it's the select statement itself, I have a created 
> an empty page that connects to MSSQL via PDO and executes the exact same 
> statement and the result is instantaneous, so this leads me to believe it's 
> a problem with the MSSQL data source packaged with Cake. If it was a driver 
> or connection issue I would assume it would happen on the test page as 
> well. Any ideas? I'm on PHP 5.3.x and am connecting to SQL Server 2008 R2.
>
> Jordan
>

-- 
Like Us on FaceBook https://www.facebook.com/CakePHP
Find us on Twitter http://twitter.com/CakePHP

--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
To post to this group, send email to cake-php@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/d/optout.


Sistema de Busca

2014-08-15 Thread Wander Arce
Boa noite,

Alguém pode indicar um plugin para criar um sistema de busca?
Caso não utilizem plugin como fariam???

Att.

Wander Arce

-- 
Like Us on FaceBook https://www.facebook.com/CakePHP
Find us on Twitter http://twitter.com/CakePHP

--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
To post to this group, send email to cake-php@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/d/optout.


Re: 3.0: a peek into CakePHP's future

2014-08-15 Thread SFranky
I don't think that shift towards ORM is a bad choice. The Model Layer of 
CakePHP was quite staightforward, but it lacked efficiency in terms of 
readibility and flexibility. The implementation of ORM might frighten the 
old folks, accustomed to Active Record Queries, but in the end its a step 
forward, which will bring more developers, who are already using these 
tehcniques. Whether we like it or not, more data abstraction will be 
applied as the tools we use and programms we write become more complex and 
powerfull.
A few drawbacks i have to mention about new version are competitiveness and 
community scale.
Frameworks like Symfony2 have already a large community which provides a 
great number of standard components (called bundles) for various types of 
web applications.
I think it would be tough for CakePHP to compete with other frameworks, 
which implemented similar techniques a long time ago and already built an 
extensive community around that.
But the one thing that still encourages me to use CakePHP is it's strcuture 
that speaks to the core of issue you are trying to solve, an approach to 
problem not as a developer but a problem solver.
I hope we will love to use CakePHP for a long time.



-- 
Like Us on FaceBook https://www.facebook.com/CakePHP
Find us on Twitter http://twitter.com/CakePHP

--- 
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to cake-php+unsubscr...@googlegroups.com.
To post to this group, send email to cake-php@googlegroups.com.
Visit this group at http://groups.google.com/group/cake-php.
For more options, visit https://groups.google.com/d/optout.


Re: Cake 2.5.1 Extremely Slow With MSSQL?

2014-08-15 Thread Dakota
Hi Alan,

The Query object does not use SQL cursors, but rather buffers the results 
locally (In PHP land) and builds lists from that.

However, CakePHP 3.0 does rely on obtaining the row count (With 
PDOStatement::rowCount), which return -1 with PDO::CURSOR_FWDONLY 
(http://technet.microsoft.com/en-us/library/ff628154(v=sql.105).aspx)

On Thursday, 14 August 2014 20:00:52 UTC+2, Alan Read wrote:
>
> I think the reasoning to use scroll was for future reasonsin CakePHP 3 
> they are introducing a new ORM layer (
> http://book.cakephp.org/3.0/en/appendices/orm-migration.html) and a Query 
> Object. I believe they are going to implement the Query Object with methods 
> like last, first, previous, next etc. With a scrollable cursor those 
> operations are mapped one to one and should be pretty fast:
>
>
>- *SCROLL: *It specifies that all fetch options (FIRST, LAST, PRIOR, 
>NEXT, RELATIVE, ABSOLUTE) are available. If SCROLL is not specified in an 
>ISO DECLARE CURSOR, NEXT is the only fetch option supported. SCROLL cannot 
>be specified if FAST_FORWARD is also specified. 
>
> (
> http://www.sqlservergeeks.com/articles/sql-server-bi/31/sql-server-what-is-a-cursor
> )
>
> If the cursor is set to FWDONLY, then the only operation available would 
> be next. In my case, with cursor set to SCROLL a simple find query was 
> taking 18 seconds to complete...since the majority of the time I just 
> forward loop through a result set, losing first, last, previous etc is not 
> that big of an issue.
>
>
>
>
> On Thu, Aug 14, 2014 at 11:31 AM, Jordan Hopfner  > wrote:
>
>> In the PHP manual it states:
>>
>> PDO::CURSOR_FWDONLY (integer 
>> ) Create a 
>> PDOStatement  object 
>> with a forward-only cursor. This is the default cursor choice, as it is the 
>> fastest and most common data access pattern in PHP. 
>> So I don't think it's a bad idea, but I don't know the reasoning the 
>> reasoning for using SCROLL over FWDONLY.
>>
>> On Thursday, August 14, 2014 6:38:47 AM UTC-6, ravag...@gmail.com wrote:
>>>
>>> I'm not sure if this is really a good idea.
>>> See:
>>> http://stackoverflow.com/questions/1155211/what-is-pdo-scrollable-cursor
>>>
>>> But if you want this find its way into the core, then you can help the 
>>> core team to get in there.
>>>
>>> Help yourself by either:
>>> a) Create an issue explaining everything on GitHub 
>>> https://github.com/cakephp/cakephp/issues/new
>>> b) Fork the code, change it, prove that it really solves the problem 
>>> without breaking anything else and create a Pull Request 
>>> https://github.com/cakephp/cakephp/
>>>
>>> Thanks
>>> Marc
>>>
>>> Am Mittwoch, 13. August 2014 16:07:26 UTC+2 schrieb Jordan Hopfner:

 Thanks Alan, appreciate the help. The project has been put on hold for 
 now but I'll definitely try this change when I go to use SQL Server again. 
 It would be great if the core team would make these changes to Cake :)

 On Friday, August 8, 2014 10:30:20 PM UTC-6, Alan Read wrote:
>
> Changing the line:
>
> 772) $prepareOptions += array(PDO::ATTR_CURSOR => PDO::CURSOR_SCROLL);
>
> to
>
> 772) $prepareOptions += array(PDO::ATTR_CURSOR => PDO::
> *CURSOR_FWDONLY*);
>
> in the _execute function inside of Sqlserver.php solved this issue for 
> me
>
> On Wednesday, May 28, 2014 5:19:09 PM UTC-4, Jordan Hopfner wrote:
>>
>> Hey guys,
>>
>> I'm using the latest version of Cake (2.5.1) and am having a problem 
>> with extremely slow connections to a MSSQL server. A controller action 
>> that 
>> only has one simple select statement is taking an upwards of 50 seconds 
>> to 
>> complete. I don't think it's the select statement itself, I have a 
>> created 
>> an empty page that connects to MSSQL via PDO and executes the exact same 
>> statement and the result is instantaneous, so this leads me to believe 
>> it's 
>> a problem with the MSSQL data source packaged with Cake. If it was a 
>> driver 
>> or connection issue I would assume it would happen on the test page as 
>> well. Any ideas? I'm on PHP 5.3.x and am connecting to SQL Server 2008 
>> R2.
>>
>> Jordan
>>
>  -- 
>> Like Us on FaceBook https://www.facebook.com/CakePHP
>> Find us on Twitter http://twitter.com/CakePHP
>>
>> --- 
>> You received this message because you are subscribed to a topic in the 
>> Google Groups "CakePHP" group.
>> To unsubscribe from this topic, visit 
>> https://groups.google.com/d/topic/cake-php/2Vqixc1UGCw/unsubscribe.
>> To unsubscribe from this group and all its topics, send an email to 
>> cake-php+u...@googlegroups.com .
>> To post to this group, send email to cake...@googlegroups.com 
>> .
>> Visit this group at http://groups.google.com/group/cake-php.
>> For more options, visit https://groups.google.com/