Re: CakePHP 3 - Where is custom datasource ?

2015-09-06 Thread Rahul Singh
Salines writes: > > > > Hi, > > I have a large number of CakePHP 2 web applications, many of them use remote data over the DataSource. I'm reading the documentation of CakePHP 3, but I can not find instructions for remote datesource. > > My next project also

Fatal error: Call to undefined method Cake\Datasource\ConnectionManager::_config() in cakephp3/vendor/cakephp/cakephp/src/Datasource/ConnectionManager.php on line 80

2015-06-16 Thread Ankit Bhardwaj
Fatal error: Call to undefined method Cake\Datasource\ConnectionManager::_config() in cakephp3/vendor/cakephp/cakephp/src/Datasource/ConnectionManager.php on line 80 This error came during installation of Cakephp 3.X on serve after putting DB details. Please help -- Like Us on FaceBook

Error: Table categories for model Categories was not found in datasource default.

2015-05-01 Thread jahabar yusuff Yusuff
error Missing Database Table Error: Table categories for model Categories was not found in datasource default. i assume that model $useTable is not working here. Controller -- Categories->find('all', array( 'conditions' => array('Cat

Re: CakePHP 3 - Where is custom datasource ?

2015-04-03 Thread Salines
Ok, thank you. -- 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 t

CakePHP 3 - Where is custom datasource ?

2015-04-03 Thread mark_story
The custom datasource approach from 2.x had a number of drawbacks and leaky abstractions which we decided we didn't want to bring forward. The new orm focuses on being really great for sql based datastores, and we felt it would be impossible to provide great sql support and every other ki

CakePHP 3 - Where is custom datasource ?

2015-04-02 Thread Salines
Hi, I have a large number of CakePHP 2 web applications, many of them use remote data over the DataSource. I'm reading the documentation of CakePHP 3, but I can not find instructions for remote datesource. My next project also requires a custom DataSource (ArangoDB), so I planned to bui

(CakePHP 2.4.1) Set $useDbConfig in a model, uses the proper DB config, but the login/password used is the one from default datasource

2014-03-05 Thread Daniel Smith
Set $useDbConfig in a model, uses the proper DB config, but the login/password used is the one from default datasource No idea what the issue is, can anyone help? Thanks -- Like Us on FaceBook https://www.facebook.com/CakePHP Find us on Twitter http://twitter.com/CakePHP --- You received

Using iCloud Calendar as DataSource

2014-01-09 Thread Dale Bengston
Hello everyone, I'm looking for an example that uses Apple's iCloud-based calendars as a CakePHP DataSource. Calendar is actually mentioned on the "CakePHP Structure" CookBook page as an example of a non-database DataSource. Actually, the page mentions iCal, which could

Trying to debug a SF datasource

2013-07-22 Thread chris graber
Curious if anyone has thoughts on this... Trying to use this to talk to Salesforce: http://bakery.cakephp.org/articles/cwestonr/2010/01/26/example-datasource-for-salesforce-enterprise-1 In the view if i try $record->Name it gives: Notice (8): Undefined property: stdClass::$Name However, I do

XML-RPC DataSource - client for Wordpress

2013-07-10 Thread Eduardo Moreira
I'm searching for an example or tutorial on how to implement a Xml-rpc client for Wordpress using the cakephp datasource. Someone has any example or tutorial to help me? Thank you. Eduardo Barbosa Moreira *Eng. Mecatrônico :: Programador Java* -- Like Us on FaceBook https://www.faceboo

Re: Model and Datasource for NoSQL (MongoDB) - relations

2013-06-19 Thread Mickaël Lagarde
Hi, Great job ! Associations work well but I have problems when I use the behavior Containable, it does not work as it should (with class extends MongodbAppModel) $results = $this->Fondeurversion->find('all', array( 'order' => array('name' => 1), 'contain' => array( 'Fondeurgamme'

Re: cake bake User - Error: Table facebooks for model Facebook was not found in datasource default.

2013-04-09 Thread lowpass
; [M]odel > [V]iew > [C]ontroller > [P]roject > [F]ixture > [T]est case > [Q]uit > What would you like to Bake? (D/M/V/C/P/F/T/Q) > > V > Error: Table facebooks for model Facebook was not found in datasource > default. > #0 /home/learning/public_html/lib/Cake/Model

Re: Cake Bake User -- Error: Table facebooks for model Facebook was not found in datasource default.

2013-04-09 Thread Nathan Pierce
> --- > Interactive Bake Shell > --- > [D]atabase Configuration > [M]odel > [V]iew > [C]ontroller > [P]roject > [F]ixture > [T]est case > [Q]uit > What would you like to Bake? (D/M/V/C/P/F/T/Q) >

Re: Cake Bake User -- Error: Table facebooks for model Facebook was not found in datasource default.

2013-04-09 Thread angelxmoreno
iguration > [M]odel > [V]iew > [C]ontroller > [P]roject > [F]ixture > [T]est case > [Q]uit > What would you like to Bake? (D/M/V/C/P/F/T/Q) > > V > Error: Table facebooks for model Facebook was not found in datasource > default. > #0 /home/learning/pub

Re: Cake Bake User -- Error: Table facebooks for model Facebook was not found in datasource default.

2013-04-08 Thread Jeremy Burns : Class Outfit
-- > [D]atabase Configuration > [M]odel > [V]iew > [C]ontroller > [P]roject > [F]ixture > [T]est case > [Q]uit > What would you like to Bake? (D/M/V/C/P/F/T/Q) > > V > Error: Table facebooks for model Facebook was not fou

cake bake User - Error: Table facebooks for model Facebook was not found in datasource default.

2013-04-08 Thread Nathan Pierce
--- [D]atabase Configuration [M]odel [V]iew [C]ontroller [P]roject [F]ixture [T]est case [Q]uit What would you like to Bake? (D/M/V/C/P/F/T/Q) > V Error: Table facebooks for model Facebook was not found in datasource default. #0 /home/learning/public_html/

Cake Bake User -- Error: Table facebooks for model Facebook was not found in datasource default.

2013-04-08 Thread Nathan Pierce
ion [M]odel [V]iew [C]ontroller [P]roject [F]ixture [T]est case [Q]uit What would you like to Bake? (D/M/V/C/P/F/T/Q) > V Error: Table facebooks for model Facebook was not found in datasource default. #0 /home/learning/public_html/lib/Cake/Model/Model.php(3237): Model->setSource('facebooks

Re: Model and Datasource for NoSQL (MongoDB) - relations

2013-03-08 Thread Vanja Dizdarević
nst convention, but makes sense since saving related data is MUCH simpler in Mongo. If the model is using an SQL datasource, the methods fall back to AppModel, so you could basically leave MongodbAppModel as the base model even with SQL drivers. It feels stupid doing it this way, but I guess it&

Re: Model and Datasource for NoSQL (MongoDB) - relations

2013-03-08 Thread Ivan Rimac
> possibilities, but for starters, I would like to mimic Cake's default model > operations. > > As I understand it, the CRUD operations on associations are generated (or > rather, instructed) by the Model class, not the DataSource class. Current > Model implementation doesn

Model and Datasource for NoSQL (MongoDB) - relations

2013-03-08 Thread Vanja Dizdarević
t model operations. As I understand it, the CRUD operations on associations are generated (or rather, instructed) by the Model class, not the DataSource class. Current Model implementation doesn't allow the datasource to decide which IDs go where and to adjust the logic of storage to the s

problem with very basic Twitter datasource example from CakePHP book

2013-02-25 Thread Arjen Voogt
Hi, Yes. I am a newbie. Working with CakePHP is a joy! But I am running into a little problem. I've implemented the Twitter datasource example from the CakePHP book (http://book.cakephp.org/1.3/en/The-Manual/Developing-with-CakePHP/DataSources.html#an-example). No typos or omissions,

Re: Datasource

2013-01-29 Thread André Luis
I got the e-mail creation working, but this message always shows, is there anyway to avoid it in datasource?? *Notice* (8): Undefined index: database [*CORE\Cake\Model\Datasource\DataSource.php*, line *102*] Thanks... Also, how can i implement the find('all') and find('first&

Datasource

2013-01-29 Thread André Luis
Hi people, i am trying to create a Datasource to connect do Cpanel API to create some e-mails directly from my administrator pannel, for this i am using the xmlapi class from Cpanel (in Vendor folder), the use is something similiar to this: $api=new xmlapi('host','username

Unit Testing, Mysql Datasource and TEXT indexes

2012-12-02 Thread Reuben
re\CakeTestFixture.php on line 210 This seems to be caused by an index I have on a TEXT field. In the original database, the index on the deceased field has a length, but it seems that CakePHP does not import key lengths for TEXT indexes, not does it support key lengths during index cre

Re: Association between a httpget json datasource and a mysql datasource.

2012-11-26 Thread Nikolas LeBlanc
dnesday, June 1, 2011 5:19:11 PM UTC-4, Philip Burrows wrote: > > Hi all, > Just wanted to know if it is possible to create an association between > a datasource that uses httpget to retrieve json and a mysql database. > I will be using www.uk-postcodes.com to find out the ward for

datasource Call to undefined method

2012-08-13 Thread mr. mohrd
Hi! I've created a simple `datasource`: // app/Model/Datasource/FeedSource.php App::uses('DataSource', 'Model/Datasource'); class FeedSource extends DataSource { public function abcd() { echo 'Hello World!'; } }

loading fixtures to a different test datasource

2012-07-27 Thread Sheetal
Hi, I have 2 datasources defined $test and $test_new in my database.php file. In my fixture files I need the table 'x_new' to be loaded in $test_new datasource, to accomplish this, with in the fixture file of the table 'x_new' I specified var $useDbConfig = 'new'

Re: Extend model/datasource to save user_id on create, update

2012-05-29 Thread luca capra
Il 29/05/2012 15:23, GB ha scritto: [...] I recall seeing this long ago but cannot find in any archives. Can anyone point me to resources on how to do this? I suspect it means extending the model in AppModel but wasn't sure if more appropriate extending the Datasource. Thanks! G

Re: Extend model/datasource to save user_id on create, update

2012-05-29 Thread euromark
ally get set on create/update. > > I recall seeing this long ago but cannot find in any archives. Can anyone > point me to resources on how to do this? I suspect it means extending the > model in AppModel but wasn't sure if more appropriate extending the > Datasource. > &

Extend model/datasource to save user_id on create, update

2012-05-29 Thread GB
t like the 'created'/'updated' timestamps automagically get set on create/update. I recall seeing this long ago but cannot find in any archives. Can anyone point me to resources on how to do this? I suspect it means extending the model in AppModel but wasn't sure if more a

Re: DataSource for CouchDB

2012-05-11 Thread Patrick Jourdan Evangelista Maia
Thanks On Thursday, May 10, 2012 8:13:45 AM UTC-3, stork wrote: > > > https://github.com/cakephp/datasources/blob/2.0/Model/Datasource/CouchdbSource.php > http://plugins.cakephp.org/packages?query=CouchDB > > -- Our newest site for the community: CakePHP Video Tutorials htt

Re: DataSource for CouchDB

2012-05-10 Thread stork
https://github.com/cakephp/datasources/blob/2.0/Model/Datasource/CouchdbSource.php http://plugins.cakephp.org/packages?query=CouchDB -- Our newest site for the community: CakePHP Video Tutorials http://tv.cakephp.org Check out the new CakePHP Questions site http://ask.cakephp.org and help

DataSource for CouchDB

2012-05-08 Thread Patrick Jourdan Evangelista Maia
I'm new to CakePHP (and also PHP) and I've started a project that uses it. I'd like to implement a DataSource to use with CouchDB and I'm wondering if there is some source of information to do so, other than this one: http://book.cakephp.org/2.0/en/models/datasources.html. T

Re: XML DataSource or solution

2012-03-30 Thread digioz
have so > far. > > I was searching online for a solution, but didn't find any (except for > code snippets here and there about writing a XML DS from scratch). I > thought about using the Array DataSource (since I can convert the XML > file into an array) but don't really

MS Access Datasource Possible?

2012-03-01 Thread skitle
Is it possible to connect to an MS Access database file as a datasource? I have checked out the Datasources plugin, and search most everywhere, and all references are pretty old and outdated. Anybody have this working for them? Thanks LaNcE -- Our newest site for the community: CakePHP Video

Re: CakePHP 2.0 Ldap Datasource and Ldap Authentication

2012-01-04 Thread Rodrigo Evildead
Very interesting! I'll test as soon as I can Thank you for your colaboration! On 3 jan, 22:36, Analog Rithems wrote: > Following the new CakePHP 2.0 release I've update the Ldap Datasource > and created a new Auth Component that follows the new framework.  I've > got a

CakePHP 2.0 Ldap Datasource and Ldap Authentication

2012-01-03 Thread Analog Rithems
Following the new CakePHP 2.0 release I've update the Ldap Datasource and created a new Auth Component that follows the new framework. I've got a small blog post about it here http://www.analogrithems.com/rant/2012/01/03/cakephp-2-0-ldapauth/ -Analog -- Our newest site for the

Re: Validation + Mongo Datasource

2012-01-03 Thread AD7six
On Dec 27 2011, 3:59 pm, RhythmicDevil wrote: > Hi all, > I am trying to get validation working for my application but I am > getting some weirdness. I have setup a custom RBAC implementation > using MongoDB and Ichikaway's datasource. > > https://github.com/ichikaway/m

ldap datasource and LdapAuth componentes

2011-12-29 Thread anagrithems
So I started porting the LdapDatasource and auth components today. So far I got hobbled together a mostly working system https://github.com/analogrithems/idbroker/tree/dev_cake2.0 but I notice that the datasource interface has changed a lot in this version. for the listSources function I see

problems with custom datasource

2011-12-28 Thread flosky
Hi everyone, I am writing a custom datasource with cake 2.x to get data from an api call. I did everything according to the twitter example in the book. But when I run a Model->find('all') I get following error message: Error: Database table examples for model Example was not foun

Re: Validation + Mongo Datasource

2011-12-28 Thread RhythmicDevil
bump x 1 On Dec 27, 9:59 am, RhythmicDevil wrote: > Hi all, > I am trying to get validation working for my application but I am > getting some weirdness. I have setup a custom RBAC implementation > using MongoDB and Ichikaway's datasource. > > https://github.com/ichik

Validation + Mongo Datasource

2011-12-27 Thread RhythmicDevil
Hi all, I am trying to get validation working for my application but I am getting some weirdness. I have setup a custom RBAC implementation using MongoDB and Ichikaway's datasource. https://github.com/ichikaway/mongoDB-Datasource I am working on validating in the Groups Model. This

CakePHP datasource & paginate results using JSON metadata

2011-12-14 Thread Salines
Hello, I just built the first *datasource* using the data in JSON format from a remote site. I receive JSON data in the following form. { "metadata": { "host": "api.examplestore.com", "path": "\/catalog\/search", "q

Re: Custom Datasource

2011-11-15 Thread RhythmicDevil
I got it working finally. This is what I ended up with: database.php public $gti = array( 'datasource' => 'GtiSource', 'url' => 'http://swright-dev:1337/' ); Model public $useDbConfig = 'gti'; Datasource filename

Re: Custom Datasource

2011-11-15 Thread RhythmicDevil
So I was using the wrong model method. I was using Model::read() instead of Model::find(). Read did not throw an error. But Find() does. Now I get this: Datasource class gti could not be found. On Nov 15, 10:26 am, RhythmicDevil wrote: > Hi All, > I am having some issues understandi

Custom Datasource

2011-11-15 Thread RhythmicDevil
Hi All, I am having some issues understanding the naming conventions for a custom datasource. datasource file name: gti_api_source.php class name GtiApiSource Database Config var $gti_api = array( 'driver' => 'gti_api', 'url&

Re: Troubles with Cake 2.0 + SQLServer datasource

2011-10-14 Thread José Lorenzo
I think you are confusing the mssql driver with the SqlSrv driver. There is no mssql in CakePHP 2.0. Sorry about that -- Our newest site for the community: CakePHP Video Tutorials http://tv.cakephp.org Check out the new CakePHP Questions site http://ask.cakephp.org and help others with their

Re: Troubles with Cake 2.0 + SQLServer datasource

2011-10-14 Thread Ernesto
There's no PDO Driver installed and i cannot install it :( -- Our newest site for the community: CakePHP Video Tutorials http://tv.cakephp.org Check out the new CakePHP Questions site http://ask.cakephp.org and help others with their CakePHP related questions. To unsubscribe from this group,

Re: Troubles with Cake 2.0 + SQLServer datasource

2011-10-11 Thread Ernesto
i forgot to say that this same app written with Cake 1.3.10, was working perfectly before migrating to 2.0. i'll check the old datasource :) -- Our newest site for the community: CakePHP Video Tutorials http://tv.cakephp.org Check out the new CakePHP Questions site http://ask.cakeph

Re: Troubles with Cake 2.0 + SQLServer datasource

2011-10-11 Thread Ernesto
Hi Mark thanks for the answer. i'll check if the PDO driver is installed. The SQL Server is a 2005 release -- Our newest site for the community: CakePHP Video Tutorials http://tv.cakephp.org Check out the new CakePHP Questions site http://ask.cakephp.org and help others with their CakePHP rel

Re: Troubles with Cake 2.0 + SQLServer datasource

2011-10-11 Thread mark_story
Have you installed the sqlsrv PDO driver? Also you'll need a recent version of SQLServer. It was developed and tested against SQLServer 2008. -Mark On Oct 10, 11:14 am, Ernesto wrote: > Hi all. > i'm having some troubles with Cake 2.0 + SQLServer datasource > > i&

Troubles with Cake 2.0 + SQLServer datasource

2011-10-10 Thread Ernesto
Hi all. i'm having some troubles with Cake 2.0 + SQLServer datasource i'm getting a "Sqlserver requires a database connection" error every time i use the "external_db" config. here's my database.php class DATABASE_CONFIG { public $default = arr

Re: SQL Server datasource is incorrect

2011-09-28 Thread mark_story
Tickets are not stored/created on github, they are on http://cakephp.lighthouseapp.com. What part of CakePHP is limited at 256 characters? The CakeSchema class and its internals are not going to support all features of every database. Some more information would be helpful. -Mark On Sep 26, 12

SQL Server datasource is incorrect

2011-09-26 Thread TapTap
The SQL Server Database has always considered varchar datatypes to be limited to 256 characters; this is true in the lastest 1.3 and 2.0RC builds. SQL Server varchars can be defined as high as 8000 characters, not 256. Is this planned to be fixed at all? I couldn't find how to post a ticket on gith

Re: cakephp 2.0 naming external datasource in database.php

2011-09-13 Thread Salines
Ispravka All my datasource files are placed in app /model/datasource as eg * youtube_source.php* -- Our newest site for the community: CakePHP Video Tutorials http://tv.cakephp.org Check out the new CakePHP Questions site http://ask.cakephp.org and help others with their CakePHP related

cakephp 2.0 naming external datasource in database.php

2011-09-13 Thread Salines
Hi, please tell me how to correctly naming the external data source in the database.php. All my datasource files are placed in app /model/datasource as eg youtube.php. *database.php* : '*YoutubeSource*', . ?> Or as described for twitter example in http://book.ca

Re: couchDB datasource

2011-07-13 Thread Clément Hallet
Hard task you're working on there ;) I have also think about automatically created views when building the datasource. That was for filtering document type too, if I remember well. Imho, the main point here is that couchDB documents can have so many shapes and format, that doing a strong ORM

Re: couchDB datasource

2011-07-13 Thread Clément Hallet
ment the CouchDB view > API (the BTree indexes are awfully fast :)), I think there is still a > lot to do to make it what I would call a "production ready" DataSource. > > Best regards > Thomas > > Am Mittwoch, den 13.07.2011, 02:10 -0700 schrieb Clément Hallet:> H

Re: couchDB datasource

2011-07-13 Thread Thomas Ploch
is shitloads of work, and it will still take me some time :) Kind regards Thomas Am Mittwoch, den 13.07.2011, 02:10 -0700 schrieb Clément Hallet: > Hello to cakePHP > > I created a CouhDB datasource at my company, and we released it as > open source. > It handles CRUD methods

Re: couchDB datasource

2011-07-13 Thread Thomas Ploch
do to make it what I would call a "production ready" DataSource. Best regards Thomas Am Mittwoch, den 13.07.2011, 02:10 -0700 schrieb Clément Hallet: > Hello to cakePHP > > I created a CouhDB datasource at my company, and we released it as > open source. > It handles

couchDB datasource

2011-07-13 Thread Clément Hallet
Hello to cakePHP I created a CouhDB datasource at my company, and we released it as open source. It handles CRUD methods on a document, and can query the CouchDB views. Code and documentation are available here : https://github.com/PathMotion/cakephp-couchsource If you're interested in r

Re: How to pass variable out of datasource

2011-06-05 Thread Abdulhakim Haliru
om what I have > used so far I can certainly see how good it is! > > For a project I have just started on, I wanted to hook up a new > datasource that would allow me to connect to the rackspace cloud. > > I dutifully set up a new datasource and with a little bit of 'pr()'

How to pass variable out of datasource

2011-06-03 Thread Struggling Sous chef
Hi, I have not been developing with cake for long, but from what I have used so far I can certainly see how good it is! For a project I have just started on, I wanted to hook up a new datasource that would allow me to connect to the rackspace cloud. I dutifully set up a new datasource and with

Re: Association between a httpget json datasource and a mysql datasource.

2011-06-02 Thread Philip Burrows
It looks like I will have to try it out. I will try and write up a tutorial when finished. Cheers Phil On Jun 1, 10:19 pm, Philip Burrows wrote: > Hi all, > Just wanted to know if it is possible to create an association between > a datasource that uses httpget to retrieve json an

Association between a httpget json datasource and a mysql datasource.

2011-06-01 Thread Philip Burrows
Hi all, Just wanted to know if it is possible to create an association between a datasource that uses httpget to retrieve json and a mysql database. I will be using www.uk-postcodes.com to find out the ward for a particular postcode, then querying my database to list the councillors in the ward

Re: accessing a function in a custom datasource, from the model

2011-05-05 Thread dreamingmind
y written properties and methods. Other times, you'll have to break out the big guns to load your class. App::import() will do that for you. http://book.cakephp.org/view/1031/Saving-Your-Data#!/view/933/The-App-Class Regards, Don On May 4, 4:21 pm, flowctrl wrote: > Hello, > > In CakeP

Re: Testing the Datasource

2011-05-05 Thread Philip Burrows
Any good tutorials on how to write schema for datasources? I can't find any. Do I even need to write the schema or can I leave the define() method blank? -- Our newest site for the community: CakePHP Video Tutorials http://tv.cakephp.org Check out the new CakePHP Questions site http://ask.cakep

accessing a function in a custom datasource, from the model

2011-05-04 Thread flowctrl
Hello, In CakePHP 1.3, how do I use a function in a custom datasource, from a model that uses that datasource? My custom datasource works for regular queries, but I want to extend the default "find" method to include a new parameter. In app/models/ datasources/foofiles_source.ph

Re: Custom datasource ignored

2011-05-04 Thread flowctrl
t; > 2011/4/30 flowctrl > > > > > Hello, > > > CakePHP seems to be ignoring the $useDbConfig variable in my model. > > I'm trying to use a custom datasource, but I'm getting the error: > > > Database table foo_files for model FooFiles was not found.

Testing the Datasource

2011-05-03 Thread Philip Burrows
Hi there, What is the best way to go about testing my datasource before building the MV & C? Should I build a simple MVC that passes everything through or shall I build the datasource independently and test it on its own? I am having difficulty understanding how to build the schema for

Re: Custom datasource ignored

2011-04-30 Thread Tilen Majerle
variable in my model. > I'm trying to use a custom datasource, but I'm getting the error: > > Database table foo_files for model FooFiles was not found. > > When I first loaded the model and new datasource, there were typos in > the datasource file which caused error

Custom datasource ignored

2011-04-30 Thread flowctrl
Hello, CakePHP seems to be ignoring the $useDbConfig variable in my model. I'm trying to use a custom datasource, but I'm getting the error: Database table foo_files for model FooFiles was not found. When I first loaded the model and new datasource, there were typos in the datasource

Re: Datasource schemas defined into models

2011-04-01 Thread Clément Hallet
Your trick would worf fine thanks. However, something still seems wrong for me, since i'm trying not to hack the whole design. Datasource::isInterfaceSupported() do what I would expect (it tells if a method is implemented). But Datasource::listSources() does actually not list the so

Re: Datasource schemas defined into models

2011-03-31 Thread Dr. Loboto
Overload DataSource::isInterfaceSupported() method to not report listSources() method as available if you don't like it so much. On Mar 31, 4:34 pm, Clément Hallet wrote: > I overloaded the $mydatasource->describe() method to return the > $model->_schema value ($model comes

Re: Datasource schemas defined into models

2011-03-31 Thread Clément Hallet
27;s focus on it : The function Model->setSource() is called to link a model to a table. While doing it, there is the next test : "if($db- >isInterfaceSupported('listSources'))" and erase the $model->_schema from the schema if true. I guess it's done to later rely

Re: Datasource schemas defined into models

2011-03-29 Thread Dr. Loboto
Model have schema() method which call describe() method of data source if supported. For manual per-model schemas you can override its schema() method. For datasource-managed schemas you should take a look into its describe() method. On 29 мар, 03:50, Clément Hallet wrote: > Hello Cake

Datasource schemas defined into models

2011-03-29 Thread Clément Hallet
Hello CakePHP, Trying to implement a CouchDB datasource and to closely follow the CakePHP guidelines, I'm in a trick situation : When saving a new record, it's required to have the fields matching the schema : https://github.com/cakephp/cakephp/blob/master/cake/libs/model/model.php#L

Datasource schemas defined into models

2011-03-29 Thread Clement Hallet
Hello CakePHP, Trying to implement a CouchDB datasource and to closely follow the CakePHP guidelines, I'm in a trick situation : When saving a new record, it's required to have the fields matching the schema : https://github.com/cakephp/cakephp/blob/master/cake/libs/model/model.ph

Re: XML DataSource or solution

2011-02-12 Thread Carlos Paparoni
Thank you for the quick reply, I appreciate it. I've tried what you suggested, and it is working, up to a point. Here is the code I'm using: DataSource - app/plugins/array_datasource/models/datasources/ array_source.php (I've only included the relevant modifications instead of

Re: XML DataSource or solution

2011-02-12 Thread Ryan Schmidt
On Feb 11, 2011, at 20:34, Carlos Paparoni wrote: > To make an update on the situation: > > I made the code work with the Array DataSource up to a point. The > problem right now is that it uses a $records array which is assigned > statically in the Model, like this: > c

Re: XML DataSource or solution

2011-02-11 Thread Carlos Paparoni
To make an update on the situation: I made the code work with the Array DataSource up to a point. The problem right now is that it uses a $records array which is assigned statically in the Model, like this: 1, 'name' => 'Alabama', 'abbr' => 'AL&

XML DataSource or solution

2011-02-11 Thread Carlos Paparoni
ar. I was searching online for a solution, but didn't find any (except for code snippets here and there about writing a XML DS from scratch). I thought about using the Array DataSource (since I can convert the XML file into an array) but don't really know how exactly to implement that. Any

Re: Datasource: Array Source - Custom Query.

2011-02-08 Thread Stephen
Hi LipeDjow That works perfectly, I can use this method throughout as well if required. Thanks for taking the time to help me with this. On 8 February 2011 12:20, LipeDjow wrote: > Humm.. you can iterate over your $query array and set the > MessageStatus.name manually. > Something like this: h

Re: Datasource: Array Source - Custom Query.

2011-02-08 Thread LipeDjow
Or, like I said in the first reply, you can get the MessageStatus.name in the view. Set MessageStatus->find('list') to a view var, and use as a translation table. I *think* that using MessageStatus over cake relations besides 'join' works too. LipeDjow -- Our newest site for the community: C

Re: Datasource: Array Source - Custom Query.

2011-02-08 Thread LipeDjow
Humm.. you can iterate over your $query array and set the MessageStatus.name manually. Something like this: http://pastie.org/private/ugpkirmaw6jevodpbudfw It's just a suggestion, I think you may test the cost of this extra iteration and the extra join (and extra table) to choose that best fit y

Re: Datasource: Array Source - Custom Query.

2011-02-07 Thread Stephen
Hi LipeDjow I'm not sure your solution will work for me, I am writing the query in my model like this: http://pastie.org/private/q4v8ypn5v8xq7crfbqcha "MessageStatus" is the model that I originally had as an ArraySource. I had to change it to run from a MySQL table. 1. Unread 2. Read 3. Delete

Re: Datasource: Array Source - Custom Query.

2011-02-07 Thread LipeDjow
Hi Stephen, You can't do a manual join with this DataSource because the table doesn't exists in the DB. My tip is: (*I don't know if this approach works for your needs) Remove the ArraySource's model from the join query. At the controller gets a list of all the elements w

Re: Datasource: Array Source - Custom Query.

2011-02-05 Thread Stephen
I should probably clarify that the array source datasource allows you to emulate a table by defining records in your model. var $records = array( > array('id' => 1, 'name' => 'Test Record') > ); > -- Kind Regards Stephen @ NinjaCoderMonkey ww

Datasource: Array Source - Custom Query.

2011-02-05 Thread Stephen
Hello there I am using the datasources plugin recommended to me in a previous post, specifically, the array source datasource. This has been working perfectly for me (see link for source code) http://pastie.org/1532389 I hita brick wall however when I was just about to do a custom join query

Extending the datasource interface / How to avoid dispatchMethod in datasource.

2011-01-18 Thread safl
Hello, I am implementing a datasource and I want to be able to invoke a method on a model which uses the datasource such as: $this->AModelUsingMyDatasource->my_method(); However it seems that all invocations on models are routed through the query method. I have implemented the fol

datasource for twitter

2010-10-01 Thread HK
Hello, I was using http://bakery.cakephp.org/articles/view/twitter-component for publishing content to twitter. But now I get a basic authentication not supported. Isn't there a newer component for twitter? I saw http://code.google.com/p/cakephp-twitter-oauth-datasource

Re: Datasource

2010-09-02 Thread Hugo M
Is not a bad idea. But, there isn't a way to get the database connection from cake and handle db pointers? Anyway, that is just curiosity, your solution seems to be right for me :), thanks! 2010/9/2 Jon Bennett > > Hi! I want to handle database pointers because I have a big database and > > memo

Re: Datasource

2010-09-02 Thread Jon Bennett
> Hi! I want to handle database pointers because I have a big database and > memory is not enough (I already added memory in php.ini and put recursive in > -1), I have like 9000 registers and I want to write all that registers in a > file. > > There's a way to do something like mysql_fetch_array wi

Datasource

2010-09-02 Thread Hugo M
Hi! I want to handle database pointers because I have a big database and memory is not enough (I already added memory in php.ini and put recursive in -1), I have like 9000 registers and I want to write all that registers in a file. There's a way to do something like mysql_fetch_array with datasour

Datasource couchdb for cakephp

2010-07-28 Thread Maury
Develop a datasource CouchDB based datasource Gwnoo (http:// bin.cakephp.org/view/925615535#modify). He is not quite complete, but has the CRUD methods working properly. With the data source also has an application example. I hope more people contribute to improve it. Link github: http

Re: Last.FM API, DataSource

2010-07-13 Thread Alexandru Ciobanu
On 7/12/2010 1:46 PM, Linuus wrote: Hi! I found this today: http://github.com/m3nt0r/last.fm-datasource-for-cakephp and wanted to try it out. I'm very new to CakePHP. I just can't get this datasource to work. I keep getting this error: "Fatal error: Call to undefined me

Last.FM API, DataSource

2010-07-12 Thread Linuus
Hi! I found this today: http://github.com/m3nt0r/last.fm-datasource-for-cakephp and wanted to try it out. I'm very new to CakePHP. I just can't get this datasource to work. I keep getting this error: "Fatal error: Call to undefined method HttpSocket::buildUri() in / Applications/

Freshbooks Datasource

2010-06-08 Thread cakeman
Hi I'm considering writing a datasource for interacting with the Freshbooks API. I have a PHP library I'd like to build the datasource on top of, but it's quite large (lots of files/includes). Does that matter? Are there any related performance/scalability issues? I guess I ha

Re: HasOne relation between model with DB like datasource a model with notDB like datasource

2010-05-14 Thread Jeremy Burns
: > Hi > I have to define a hasOne relation between model (model A) with DB > like datasource a model (model B) with datasource that isn't a DB. > If I have this controller operation: > > pr($this->ModelA->find('all')); > die();

HasOne relation between model with DB like datasource a model with notDB like datasource

2010-05-14 Thread marco.rizze...@gmail.com
Hi I have to define a hasOne relation between model (model A) with DB like datasource a model (model B) with datasource that isn't a DB. If I have this controller operation: pr($this->ModelA->find('all')); die(); I have noted that CakePHP

  1   2   >