Re: [doctrine-user] Vulnerability DB Report A Security Vulnerabilities

2021-04-21 Thread Marco Pivetta
It is not a false positive: it is a critical bug that can potentially lead to data exfiltration. The report is wrong in its version range though: only 2.8.3 is affected, while both 2.8.2 and 2.8.4 are OK. https://github.com/FriendsOfPHP/security-advisories/pull/548 On Wed, Apr 21, 2021, 05:00

Re: [doctrine-user] Is there any way to use related objects in conditions?

2020-06-05 Thread Marco Pivetta
This is called "arbitrary joins" in DQL: ```php createQuery('SELECT u FROM User u JOIN Blacklist b WITH u.email = b.email'); ``` See https://www.doctrine-project.org/projects/doctrine-orm/en/2.7/reference/dql-doctrine-query-language.html Marco Pivetta http://twitter.com/Ocra

Re: [doctrine-user] Is there any in-depth reference documentation for the Doctrine APIs?

2020-05-18 Thread Marco Pivetta
on the comments that you mentioned in order to infer proper types. Marco Pivetta http://twitter.com/Ocramius http://ocramius.github.com/ On Mon, May 18, 2020 at 11:33 AM Mattia Basaglia wrote: > I was looking at the documentation website, it lists a bunch of examples, > tutorials, and other

Re: [doctrine-user] Doctrine 3 features and timeline

2019-10-03 Thread Marco Pivetta
Hi Vincent, On Thu, Oct 3, 2019, 09:51 Vincent Pazeller wrote: > Hi all, > > I have seen that the doctrine team is working on the doctrine 3 branch... > is there any documentation that gives informations on: > - What are the big changes/improvements planned in this major release? > Mostly

Re: [doctrine-user] Using array_splice for removing collection items instead of unset

2019-09-30 Thread Marco Pivetta
. Marco Pivetta http://twitter.com/Ocramius http://ocramius.github.com/ On Mon, Sep 30, 2019 at 12:03 PM naitsirch wrote: > Hi, > > I would like to ask why `unset` is used when collection items are removed > (e.g. > https://github.com/doctrine/collections/blob/master/lib/Doctrine/Com

Re: [doctrine-user] Can't discover pear.doctrine-project.org

2019-09-06 Thread Marco Pivetta
Heya, Pear is gone-gone-gone. It won't be supported anymore, and it was shut down many years ago. Marco Pivetta http://twitter.com/Ocramius http://ocramius.github.com/ On Fri, Sep 6, 2019 at 5:46 PM Tommy Sparks wrote: > Hello, > > I am trying to install some prerequisites for P

Re: [doctrine-user] Cannot connect to MySQL Instance on AWS From Doctrine PHP

2019-06-27 Thread Marco Pivetta
$pdo = new PDO(/* parameters */); var_dump($pdo->query('SELECT 1')->fetch()); Marco Pivetta http://twitter.com/Ocramius http://ocramius.github.com/ On Thu, Jun 27, 2019 at 9:22 PM Nathaniel Goodwin wrote: > I am able to connect via the ubuntu bsh command line and I am able to >

Re: [doctrine-user] Cannot connect to MySQL Instance on AWS From Doctrine PHP

2019-06-27 Thread Marco Pivetta
Are you able to connect with plain PDO? Marco Pivetta http://twitter.com/Ocramius http://ocramius.github.com/ On Thu, Jun 27, 2019 at 9:03 PM Nathaniel Goodwin wrote: > Using > > ``` > "php": "^7.1.3", > "doctrine/doctrine-bundle

Re: [doctrine-user] Querybuilder - Two joins leads to wrong sum results

2019-06-09 Thread Marco Pivetta
On Sun, Jun 9, 2019 at 10:40 PM Askan Simon wrote: > > Is there a solution for such cases in Doctrine ORM? Currently I use raw > sql querys with subselects ... > Which is perfectly fine ;-) Marco Pivetta http://twitter.com/Ocramius http://ocramius.github.com/ -- You received

Re: [doctrine-user] is it possible to use oracle NLSSORT(name, 'NLS_SORT=german') function in DQL?

2019-05-12 Thread Marco Pivetta
Heya, Please look into custom DQL functions. On Thu, 9 May 2019, 22:36 eagle on, wrote: > soemthign like this: > > SELECT * FROM test3 ORDER BY NLSSORT(name, 'NLS_SORT=german'); > > -- > You received this message because you are subscribed to the Google Groups > "doctrine-user" group. > To

Re: [doctrine-user] Best way to set up a directed acyclic graph?

2019-01-22 Thread Marco Pivetta
There's DoctrineExtensions' NestedSet. Don't think it goes much further than that though. On Mon, 21 Jan 2019, 23:58 Iain Hallam I'm fairly new to Doctrine ORM, but I'm trying to model nested groups that > can be members of multiple other groups, so this isn't a tree. I found an > interesting

Re: [doctrine-user] Doctrine doesn't allow now DESCENDANT indexes, WHY ?

2019-01-04 Thread Marco Pivetta
ine developers group" and I ended in this group. o_O > > Do you have a url? > > I think doctrine coul easily convert this "undocumented feature" in a > "valid feature" to translate > "=" > > Thanks > > > El viernes, 4 de enero de

Re: [doctrine-user] Doctrine doesn't allow now DESCENDANT indexes, WHY ?

2019-01-04 Thread Marco Pivetta
Doctrine only targets cross-platform compliant features. The undocumented "feature" you are using was working because of incorrect DBAL quoting semantics in DDL: if you need it, I suggest opening a pull request with a failing test, for discussion/inclusion in the tooling. On Fri, 4 Jan 2019,

Re: [doctrine-user] Json format - Reverse the relation owner

2018-12-26 Thread Marco Pivetta
This doesn't seem to be a doctrine-related questions, but rather something for the serialisation layer/library you rely upon. On Wed, 26 Dec 2018, 14:53 Jose Julian Hi, i use Donctrine 2.6.3 on a symfony 4.2 proyect(REST API). > and i have som trouble with some json generated > Theres is 2 basic

Re: [doctrine-user] Composite Key Order?

2018-11-30 Thread Marco Pivetta
t; order, why is it trying to reorder them at all then? > > A manual migration isn't going to help me here... I don't want to change > anything, I want to prevent doctrine from thinking it needs to change > something. > > > On Wednesday, November 28, 2018 at 9:40:59 AM UTC-8, Marco

Re: [doctrine-user] Composite Key Order?

2018-11-28 Thread Marco Pivetta
I'd avoid YML mappings overall, since they are deprecated and removed from ORM `master`. Still, order of columns in a key is not guaranteed anywhere in the ORM, so there's no real way to enforce the DDL to match your requirements. Consider using manually crafted doctrine migrations instead. On

Re: [doctrine-user] Re: MySQL 8 Connection Refused Issue resolved - But why?

2018-11-19 Thread Marco Pivetta
I don't think this has anything to do with Doctrine at all: this is a known quirk of ext-pdo. On Mon, 19 Nov 2018, 22:15 David Stokes One of our developers informed me that libmysql and all derived clients > interpret "localhost" to mean "don't use TCP/ip, but Unix domain socket" > > Is there

Re: [doctrine-user] MySQL 8 Connection Refused Issue resolved - But why?

2018-11-19 Thread Marco Pivetta
That's PDO trying to outsmart things and trying to use a local socket when localhost is used: not something Doctrine can really fix. On Mon, 19 Nov 2018, 19:42 David Stokes Hi All, > > I am using Doctrine with MySQL 8.0.13 and ran into what looks like > something odd to me. I am using an

Re: [doctrine-user] What is the best way to reset dbal querybuilder setMaxResults?

2018-11-01 Thread Marco Pivetta
n our case it is injected into the class constructor. Are you suggesting that each method within a class/model has a instance? On Thu, Nov 1, 2018, 8:11 PM Marco Pivetta I didn't even know you could "reset" a query builder: why not simply > making a new instance? Note that builder

Re: [doctrine-user] What is the best way to reset dbal querybuilder setMaxResults?

2018-11-01 Thread Marco Pivetta
I didn't even know you could "reset" a query builder: why not simply making a new instance? Note that builder objects aren't usually services/injectables. On 1 Nov 2018 18:27, "Nate Braner" wrote: Hey everyone, So we are using doctrine/dbal outside of Symfony as we gear up to move the project

Re: [doctrine-user] Pre load data on install

2018-10-12 Thread Marco Pivetta
For deployment environments, I use migrations to seed the initial state (if it is common to all deployment environments). For testing, I rely heavily on data-fixtures. On Fri, 12 Oct 2018, 10:05 Plamen Vasilev, wrote: > Hi all, > > what should I do to load data (like users, roles and etc.)

Re: [doctrine-user] Re: Wrong Entity names generated from database (postgres with diferent schemas)

2018-09-21 Thread Marco Pivetta
you said that PHP 5.6 was not supported anymore, I installed a new > server with PHP7, I integrated all doctrine latest projects from github so > now I have an updated doctrine, I ran the command again and the problem > persists. > > El jueves, 20 de septiembre de 2018, 18:54:11 (UTC

Re: [doctrine-user] Re: Wrong Entity names generated from database (postgres with diferent schemas)

2018-09-20 Thread Marco Pivetta
No, you will just need to upgrade your stack: PHP 5.6 is definitely *NOT* supported anymore. On 21 Sep 2018 00:48, "Dunior Socarras" wrote: Yes, I just tried with dbal-2.8.0 and orm-2.6.2, but some errors came out because I'm using PHP 5.6 and in this versions of orm and dbal are using "??"

Re: [doctrine-user] Wrong Entity names generated from database (postgres with diferent schemas)

2018-09-20 Thread Marco Pivetta
Did you already try with newest DBAL/ORM? On Thu, 20 Sep 2018, 06:25 Dunior Socarras, wrote: > I'm using Doctrine 2.5, I have a database in PostgreSQL 6 and my tables > are inside diferent schemas. > When I excecute the command "doctrine orm:convert-mapping --from-database > annotation",

Re: [doctrine-user] Re: Help for Association Mapping, please (->

2018-08-23 Thread Marco Pivetta
Can you be more specific about "nothing works"? Can you maybe put up an example script on gist.github.com? On Fri, 24 Aug 2018, 02:05 , wrote: > Thanks, but nothing works ... > > Le jeudi 23 août 2018 18:55:23 UTC+2, breth...@gmail.com a écrit : >> >> Hi, >> >> I read all I can read about this

Re: [doctrine-user] Re: Help for Association Mapping, please (->

2018-08-23 Thread Marco Pivetta
/** @ORM\Id() @ORM\Column() */ public $id; /** @ORM\ManyToOne(targetEntity=User::class, inversedBy="skills") */ public $skills; } Marco Pivetta http://twitter.com/Ocramius http://ocramius.github.com/ On Thu, Aug 23, 2018 at 9:37 PM wrote: > Tanks for your advises

Re: [doctrine-user] Help for Association Mapping, please (->

2018-08-23 Thread Marco Pivetta
Heya, Could you maybe reduce your examples to something that fits in a mail? What is not working about JoinColumn? Also, do you really need to define a join column? That's usually for later on, when you already built up some experience with the ORM. On Thu, 23 Aug 2018, 18:55 , wrote: > Hi, >

Re: [doctrine-user] Connecting to SQLSrv 2005 using FreeTDS

2018-03-23 Thread Marco Pivetta
FWIW, we just dropped support for that version in the development branch: I suggest simply upgrading to a maintained version of SQL Server first, as you are hereby dealing with something properly ancient. On 23 Mar 2018 04:52, "Leandro Damascena" wrote: > Hi > Can I

Re: [doctrine-user] Connect Informix / Doctrine / PHP

2018-02-26 Thread Marco Pivetta
See https://github.com/doctrine/dbal/issues/1200 On 26 Feb 2018 19:55, "Iury Cardoso" wrote: > Hello, > > I would like a help ... How do I connect to DB informix, with php by > doctrine? > > I've tried every way but I can not in any way. Can someone hug me? > > Thank you

Re: [doctrine-user] How to use polymorphism with Doctrine?

2018-02-15 Thread Marco Pivetta
See https://github.com/doctrine/doctrine2/issues/6072#issuecomment-363038318 Marco Pivetta http://twitter.com/Ocramius http://ocramius.github.com/ On Thu, Feb 15, 2018 at 3:48 PM, Dennis Matveyev <denny...@gmail.com> wrote: > Consider this code: > public function g

Re: [doctrine-user] problem following the tutorial :/

2018-02-12 Thread Marco Pivetta
What's your configuration, and where is the entity located? Marco Pivetta http://twitter.com/Ocramius http://ocramius.github.com/ On Tue, Feb 13, 2018 at 8:53 AM, Christophe G <tof...@gmail.com> wrote: > Hello all, > I have a problem just following the tutorial http://docs.doct

Re: [doctrine-user] One to Many relation between 3 entities

2018-02-08 Thread Marco Pivetta
If you are creating a child entity and never persisting it explicitly, then a cascade should be defined. Marco Pivetta http://twitter.com/Ocramius http://ocramius.github.com/ On Thu, Feb 8, 2018 at 11:52 AM, Sander <sandervanmoo...@gmail.com> wrote: > Hi, > > I'm havi

Re: [doctrine-user] Problem with subentities with discriminator column in query result

2017-12-29 Thread Marco Pivetta
, the filtering is subtle because you used a JOIN condition twice, and that implicitly acts as restriction. Marco Pivetta http://twitter.com/Ocramius http://ocramius.github.com/ On Fri, Dec 29, 2017 at 3:24 PM, <ffdede...@gmail.com> wrote: > We have some problems querying an entity with emb

Re: [doctrine-user] xml namespace prefix for xsd

2017-11-04 Thread Marco Pivetta
Yeah, if you can, you can help also with improving the docs - same as the other thread, just need to get started with GIT and github :-) Marco Pivetta http://twitter.com/Ocramius http://ocramius.github.com/ On Sat, Nov 4, 2017 at 6:39 PM, Артем Мельчук <artyom.melc...@gmail.com> wrote:

Re: [doctrine-user] xml custom-id-generator class attribute type nmtoken

2017-11-04 Thread Marco Pivetta
Probably IRC, yes, although you can refer to https://yangsu.github.io/pull-request-tutorial/ to get started Marco Pivetta http://twitter.com/Ocramius http://ocramius.github.com/ On Sat, Nov 4, 2017 at 6:45 PM, Артем Мельчук <artyom.melc...@gmail.com> wrote: > Thx a lot! What is

Re: [doctrine-user] Entity generation directory layout

2017-11-04 Thread Marco Pivetta
It's not supposed to be hacked - it is intended behavior. If you need the generated files to be moved somewhere else, you will need to do so yourself Marco Pivetta http://twitter.com/Ocramius http://ocramius.github.com/ On Sat, Nov 4, 2017 at 6:47 PM, Артем Мельчук <artyom.melc...@gmail.

Re: [doctrine-user] Entity generation directory layout

2017-11-04 Thread Marco Pivetta
The entities are always generated in a PSR-0 (*not* PSR-4) compliant structure given a root directory. Marco Pivetta http://twitter.com/Ocramius http://ocramius.github.com/ On Sat, Nov 4, 2017 at 5:46 PM, MetaAbstract <artyom.melc...@gmail.com> wrote: > I generate entities from xml

Re: [doctrine-user] xml namespace prefix for xsd

2017-11-04 Thread Marco Pivetta
This is normal behavior of the metadata drivers: they can't currently deal with standard NS prefixing. Marco Pivetta http://twitter.com/Ocramius http://ocramius.github.com/ On Sat, Nov 4, 2017 at 5:24 PM, MetaAbstract <artyom.melc...@gmail.com> wrote: > By default my IDE a

Re: [doctrine-user] xml custom-id-generator class attribute type nmtoken

2017-11-04 Thread Marco Pivetta
, and that is fixed once you apply your patch to the XSD :-) Marco Pivetta http://twitter.com/Ocramius http://ocramius.github.com/ On Sat, Nov 4, 2017 at 3:51 PM, Артем Мельчук <artyom.melc...@gmail.com> wrote: > it's here: > > > > > > > &g

Re: [doctrine-user] xml custom-id-generator class attribute type nmtoken

2017-11-04 Thread Marco Pivetta
Send a patch with a test  On 4 Nov 2017 13:48, "MetaAbstract" wrote: > Hi, > I define custom id generator and can't define class for custom id > generator because class is nmtoken type not string. XSD checker give error > for class name. > > > >

Re: [doctrine-user] how to inherit an entity behaviour? how write an engine for an applications?

2017-10-24 Thread Marco Pivetta
rt mapping associations. Marco Pivetta http://twitter.com/Ocramius http://ocramius.github.com/ On Tue, Oct 24, 2017 at 2:24 PM, OdaepO <oda...@gmail.com> wrote: > >I don't think this has anything to do with the ORM specifically > > sorry if I was not clear... > I was meaning w

Re: [doctrine-user] how to inherit an entity behaviour? how write an engine for an applications?

2017-10-24 Thread Marco Pivetta
Hi there, I don't think this has anything to do with the ORM specifically: you should first design the interactions in your system, and leave the data requirements emerge from that. Persistence/ORM comes after all that stuff is finished. Marco Pivetta http://twitter.com/Ocramius http

Re: [doctrine-user] localhost db vs remote db performance degradation

2017-10-21 Thread Marco Pivetta
Possibly just amount of network time involved: you should at least have the DB close to your server (for less-than-10ms pings). The roundtrip for a high amount of queries is obviously always going to be a disaster. Try attaching an SQL logger and see the query times for both environments? On 21

Re: [doctrine-user] Immutable Entities and Uuids - what should i do ?

2017-10-10 Thread Marco Pivetta
bother asking for your advice/opinion in the first place. On Tuesday, October 10, 2017 at 1:17:16 AM UTC+2, Marco Pivetta wrote: > Why is everyone stuck with this silly performance question? > > Let's talk again when we have 100M+ records, shall we? Until then, it's > 16b vs 2b. >

Re: [doctrine-user] Immutable Entities and Uuids - what should i do ?

2017-10-09 Thread Marco Pivetta
Why is everyone stuck with this silly performance question? Let's talk again when we have 100M+ records, shall we? Until then, it's 16b vs 2b. The fact that you are using PHP is your first performance/memory bottleneck. Marco Pivetta http://twitter.com/Ocramius http://ocramius.github.com

Re: [doctrine-user] Entity collection changes

2017-09-27 Thread Marco Pivetta
See `UnitOfWork#getScheduledCollectionUpdates()` Marco Pivetta http://twitter.com/Ocramius http://ocramius.github.com/ On Wed, Sep 27, 2017 at 1:32 PM, Plamen V. Vasilev < plamen.v.vasi...@circles.bz> wrote: > I have changed which have to be the owning side according to th

Re: [doctrine-user] Entity collection changes

2017-09-27 Thread Marco Pivetta
Only the owning side of the association will then contain changes ;-) Marco Pivetta http://twitter.com/Ocramius http://ocramius.github.com/ On Wed, Sep 27, 2017 at 10:50 AM, Plamen V. Vasilev < plamen.v.vasi...@circles.bz> wrote: > Sorry, I'm wrong .. the relation is ManyToMany wit

Re: [doctrine-user] Entity collection changes

2017-09-27 Thread Marco Pivetta
Are you sure that you don't have a OneToMany rather than a ManyToOne? OneToMany is completely ignored by the ORM, so you won't get any diffs there. Marco Pivetta http://twitter.com/Ocramius http://ocramius.github.com/ On Wed, Sep 27, 2017 at 9:16 AM, <plamen.v.vasi...@circles.bz>

Re: [doctrine-user] Entity collection changes

2017-09-26 Thread Marco Pivetta
Your message came through clipped: can you re-send it as a new thread? Marco Pivetta http://twitter.com/Ocramius http://ocramius.github.com/ On Tue, Sep 26, 2017 at 4:54 PM, <plamen.v.vasi...@circles.bz> wrote: > > Hi all, > > does any one knows how I can get the entity Ma

Re: [doctrine-user] Odd thing on migration diff and also when doing update:schema --force

2017-09-20 Thread Marco Pivetta
The same suggestions as before apply: do write a test case. Marco Pivetta http://twitter.com/Ocramius http://ocramius.github.com/ On Wed, Sep 20, 2017 at 12:42 PM, Przemyslaw Furtak <przemysl...@gmail.com> wrote: > I forgot to mention that I'm using MySQL engine so this may be

Re: [doctrine-user] Where can I find a list of supported databases?

2017-09-17 Thread Marco Pivetta
See https://github.com/doctrine/dbal/tree/v2.6.2/lib/Doctrine/DBAL/Platforms On 17 Sep 2017 09:33, wrote: > Hello > > Im interested in using Doctrine. But first I want to check that our > prefered database is supported. > Where can I find which databases are supported by

Re: [doctrine-user] Mapping postFlush entity listener with annotations

2017-08-25 Thread Marco Pivetta
No, it is correct that these are not included: the flush does not happen on an entity, but on the entire UnitOfWork. An entity is added/removed/updated/inserted/deleted/etc, not flushed. Marco Pivetta http://twitter.com/Ocramius http://ocramius.github.com/ On Fri, Aug 25, 2017 at 5:55 PM

Re: [doctrine-user] Mapping postFlush entity listener with annotations

2017-08-25 Thread Marco Pivetta
This is normal, as `postFlush` is not part of the lifecycle of an entity. Marco Pivetta http://twitter.com/Ocramius http://ocramius.github.com/ On Fri, Aug 25, 2017 at 5:37 PM, Steffen Roßkamp < sinistral.dext...@gmail.com> wrote: > It seems that the postFlush event can

Re: [doctrine-user] [help] DQL query result problem when intermediate query run

2017-08-25 Thread Marco Pivetta
On Wed, Aug 23, 2017 at 9:29 AM, Andreas Goetz <cpui...@gmail.com> wrote: > Hi Marco, > > On Wednesday, August 23, 2017 at 9:23:33 AM UTC+2, Marco Pivetta wrote: >> >> You are filtering a fetch-joined association: that will break hydration. >> We never manager to

Re: [doctrine-user] Entity collection original state

2017-08-15 Thread Marco Pivetta
That's what the `PersistentCollection#getSnapshot()` API would give you, although only if the collection was initialised. The original collection data may be unknown if the collection was never initialised. Also, please note that this is internal API. On 15 Aug 2017 11:25 AM,

Re: [doctrine-user] How to get query generated by flush for a specific object?

2017-06-29 Thread Marco Pivetta
This is not supported, and we'll not add endpoints to allow this unless there is a strong use-case scenario to support it. Marco Pivetta http://twitter.com/Ocramius http://ocramius.github.com/ On Thu, Jun 29, 2017 at 9:59 AM, Kleand Sherali <kleandsher...@gmail.com> wrote: > Whe

Re: [doctrine-user] Limit the many side of a one to many

2017-06-27 Thread Marco Pivetta
ncy, but hydrating broken objects is a no-go Marco Pivetta http://twitter.com/Ocramius http://ocramius.github.com/ On Tue, Jun 27, 2017 at 9:05 AM, Joshua Wilson <kor...@gmail.com> wrote: > These are my 2 classes > > class Bill implements Searchable > { > use \Laravel

Re: [doctrine-user] Limit the many side of a one to many

2017-06-27 Thread Marco Pivetta
y, then does it matter if the data > is 'corrupted'? If it does not matter, I would like to do it lol. > > On Tuesday, June 27, 2017 at 1:14:41 AM UTC-5, Marco Pivetta wrote: >> >> You still cannot hydrate a `Bill` object with a subset of `Favorite` >> instances in it, as that

Re: [doctrine-user] Limit the many side of a one to many

2017-06-27 Thread Marco Pivetta
f1.user = :user OR f1.user IS NULL) Marco Pivetta http://twitter.com/Ocramius http://ocramius.github.com/ On Tue, Jun 27, 2017 at 8:11 AM, Joshua Wilson <kor...@gmail.com> wrote: > That would end up being a problem as I would only see a subset of bills > where as I want the c

Re: [doctrine-user] Limit the many side of a one to many

2017-06-27 Thread Marco Pivetta
f1.user = :user OR f1.user IS NULL) Marco Pivetta http://twitter.com/Ocramius http://ocramius.github.com/ On Tue, Jun 27, 2017 at 7:58 AM, Joshua Wilson <kor...@gmail.com> wrote: > Actaully, based on your first response, I went back at looked at the > criteria builder even more

Re: [doctrine-user] Limit the many side of a one to many

2017-06-26 Thread Marco Pivetta
That's possible via DQL, but it is a bad idea because your data will be corrupted at hydration. Did you already look at the criteria API? On 27 Jun 2017 6:00 AM, "Joshua Wilson" wrote: > Hey guys, > > I have looked all over but so far havent found anything that might help. >

Re: [doctrine-user] Declare Doctrine Embeddable as nullable or not

2017-06-20 Thread Marco Pivetta
See https://github.com/doctrine/doctrine2/issues/4568 Marco Pivetta http://twitter.com/Ocramius http://ocramius.github.com/ On Tue, Jun 20, 2017 at 9:44 AM, Marc Verney <m...@marcverney.net> wrote: > Hello, > > Let's say I've got two Doctrine entities, Person and Com

Re: [doctrine-user] Doctrine_Query no does not replace names in build SQL functions

2017-06-12 Thread Marco Pivetta
Doctrine 1.x is dead since years: you will likely not get any support with it. On 12 Jun 2017 08:38, "Jaroslav Zeman" wrote: Hi all I am create SQL over Doctrine 1.2: $query = \Doctrine_Query::create(); $query->from('Zone object');

Re: [doctrine-user] Zend/Symfony-Services: Using a EntityManager in a Service in a EventSubscriber

2017-06-08 Thread Marco Pivetta
he DI from crashing at initialization. Marco Pivetta http://twitter.com/Ocramius http://ocramius.github.com/ On Thu, Jun 8, 2017 at 4:16 PM, Kai Szymanski <k...@szymanski.de> wrote: > Hi, > > > EventSubsriberA use Mailserver - max, Nested Function call (because of > getting the

Re: [doctrine-user] Zend/Symfony-Services: Using a EntityManager in a Service in a EventSubscriber

2017-06-08 Thread Marco Pivetta
Heya, The object manager is usually given by the event being fired, so you don't need to inject it. Marco Pivetta http://twitter.com/Ocramius http://ocramius.github.com/ On Thu, Jun 8, 2017 at 1:12 PM, Kai Szymanski <k...@szymanski.de> wrote: > Hi, > > sound funny, i know :)

Re: [doctrine-user] Odd thing on migration diff and also when doing update:schema --force

2017-05-04 Thread Marco Pivetta
that the diff is empty Marco Pivetta http://twitter.com/Ocramius http://ocramius.github.com/ On Thu, May 4, 2017 at 1:33 PM, Andrew Davey <a...@mediabandit.co.uk> wrote: > I've noticed this for a while now and i'm unsure what the issue is and > what it's happening. > >

Re: [doctrine-user] Find all Entities with foreign keys to a specific Entity

2017-04-08 Thread Marco Pivetta
That is pretty much it - you'd just need to tinker with `$em->getClassMetadataFactory()->getAllMetadata()` and the `ClassMetadata#getAssociationNames()` method Marco Pivetta http://twitter.com/Ocramius http://ocramius.github.com/ On Sun, Apr 9, 2017 at 12:17 AM, Michael Krasno

Re: [doctrine-user] Find all Entities with foreign keys to a specific Entity

2017-04-07 Thread Marco Pivetta
Using the ClassMetadata API, this should be trivial. What have you tried so far? On 8 Apr 2017 4:23 a.m., "Michael Krasnow" wrote: > Hi all, > > I have a need to find all entities that have foreign keys to a specific > Entity. > I searched around but could not find any leads.

Re: [doctrine-user] Doctrine 2 - Can't set composite primary key named “id”

2017-03-24 Thread Marco Pivetta
I'm specifically asking for a test case: see https://github.com/doctrine/doctrine2/tree/d3f6c5ec70aac4b029a4b61ecf1e2ba61a1a4a6d/tests/Doctrine/Tests/ORM/Functional/Ticket for examples. Marco Pivetta http://twitter.com/Ocramius http://ocramius.github.com/ On Fri, Mar 24, 2017 at 1:13 PM

Re: [doctrine-user] Doctrine 2 - Can't set composite primary key named “id”

2017-03-22 Thread Marco Pivetta
? * Is such a complex identifier really needed? Marco Pivetta http://twitter.com/Ocramius http://ocramius.github.com/ On Wed, Mar 22, 2017 at 9:57 AM, springercreative via doctrine-user < doctrine-user@googlegroups.com> wrote: > I'm writing at the moment a fixture loader command

Re: [doctrine-user] Query with multiple inner sections

2017-03-13 Thread Marco Pivetta
What's the problem with this? Could you clarify what this is supposed to do, what it is doing instead, and maybe an example test scenario around it? Marco Pivetta http://twitter.com/Ocramius http://ocramius.github.com/ On Mon, Mar 13, 2017 at 10:41 AM, Anoop Govindan <anoo...@doreming.

Re: [doctrine-user] Are bidirectional relationships worth the trouble?

2017-03-02 Thread Marco Pivetta
t a > simple query always do the same thing? > > SELECT * FROM `Employees` e WHERE e.role = `Manager`; > > Your question really isn't clear. Could you rephrase it a bit, and add more examples? Marco Pivetta http://twitter.com/Ocramius http://ocramius.github.com/ -- You received this m

Re: [doctrine-user] Doctrine 1.2 Update

2017-02-10 Thread Marco Pivetta
e back. > Help is appreciated, but Doctrine 1.x is abandoned :-\ Marco Pivetta http://twitter.com/Ocramius http://ocramius.github.com/ -- You received this message because you are subscribed to the Google Groups "doctrine-user" group. To unsubscribe from this group and stop receiving e

Re: [doctrine-user] Creating a relationship for users that are invited by a user

2017-02-02 Thread Marco Pivetta
The exception states that `AppBundle\Entity\User#InvitedBy` is not mapped as `inversedBy="InvitedBy"` Your naming makes this a bit confusing Marco Pivetta http://twitter.com/Ocramius http://ocramius.github.com/ On Thu, Feb 2, 2017 at 11:39 AM, Andrew Davey <a...@mediabandit.co.uk

Re: [doctrine-user] Extending \Doctrine\DBAL\Connection, private methods

2017-01-19 Thread Marco Pivetta
Also: copying the method is perfectly OK :-) Marco Pivetta http://twitter.com/Ocramius http://ocramius.github.com/ On Thu, Jan 19, 2017 at 2:54 PM, Peter Bowyer <pe...@mapledesign.co.uk> wrote: > Thanks Marco. > > Peter > > On Thursday, 19 January 2017 11:58:40 UTC

Re: [doctrine-user] Extending \Doctrine\DBAL\Connection, private methods

2017-01-19 Thread Marco Pivetta
The correct approach would be to extract the method into either: * a static utility * an injected dependency Reuse through `protected` only leads to a massive amount of coupling, and more BC concerns for us. Marco Pivetta http://twitter.com/Ocramius http://ocramius.github.com/ On Thu, Jan

Re: [doctrine-user] About the order of lifecycle event listener calls

2017-01-13 Thread Marco Pivetta
This is currently not supported by the EventManager, as our implementation is simplistic for performance reasons. Still, it is achieved anyway by registering the listeners in the correct order. On 13 Jan 2017 9:09 p.m., "Guite" wrote: > Hi all, > > I want to know whether

Re: [doctrine-user] Filtering of subclasses

2017-01-05 Thread Marco Pivetta
in https://github.com/doctrine/doctrine2/issues/2237 Marco Pivetta http://twitter.com/Ocramius http://ocramius.github.com/ On Thu, Jan 5, 2017 at 11:41 AM, Lukas Hofer <hoferluk...@gmail.com> wrote: > Hi! I have the following structure of entities: Customer is the parent > class an

Re: [doctrine-user] Doctrine GROUP BY ANY_VALUE

2016-12-30 Thread Marco Pivetta
unt(d.nom) as lignes'); > $qb->groupBy('d.nom'); > $qb->orderBy('d.nom'); > > But doctrine don't recognize this function > > [2/2] QueryException: [Syntax Error] line 0, col 7: Error: Expected known > function, got 'ANY_VALUE' > > How can I resolve it ? > >

Re: [doctrine-user] Sql é exibida na tela após uma consulta

2016-12-14 Thread Marco Pivetta
Hi Carlos, Can you please show what you've attempted so far? Also, please try to keep messages in English, as that's the language for this mailing list. Greets, Marco Pivetta http://twitter.com/Ocramius http://ocramius.github.com/ 2016-12-14 19:22 GMT+01:00 Werliton Carlos <werliton

Re: [doctrine-user] adding doctrine/common 2.7 in composer

2016-12-01 Thread Marco Pivetta
We need to release an ORM version supporting common 2.7. for now, you can use composer's `AS` dependency require workaround. -- You received this message because you are subscribed to the Google Groups "doctrine-user" group. To unsubscribe from this group and stop receiving emails from it, send

Re: [doctrine-user] Composite and foreign keys issue

2016-10-27 Thread Marco Pivetta
, "Maksim Borisov" <maksim.i.bori...@gmail.com> wrote: > Thank you, Marco. > > Can you help newbie to send feature request to doctrine-team for that > case? How can I do it? > > четверг, 27 октября 2016 г., 7:14:17 UTC+7 пользователь Marco Pivetta > написал: &g

Re: [doctrine-user] Composite and foreign keys issue

2016-10-26 Thread Marco Pivetta
That's an ORM limitation that you are hitting. The ORM doesn't really know (yet? nobody working on this, so far) how to deal with multiple levels of identity indirection, at the moment. Marco Pivetta http://twitter.com/Ocramius http://ocramius.github.com/ On Thu, Sep 29, 2016 at 6:15 PM

Re: [doctrine-user] Bug in AssignedGenerator.php

2016-09-29 Thread Marco Pivetta
/Functional/Ticket/DDC992Test.php, for example (just adapted to your scenario). Marco Pivetta http://twitter.com/Ocramius http://ocramius.github.com/ On Thu, Sep 29, 2016 at 4:42 PM, Janelle Tavares <jta...@gmail.com> wrote: > I believe that I found a bug in the lates

Re: [doctrine-user] Re: How to force column's default value? MSSQL, Symfony Entity

2016-09-28 Thread Marco Pivetta
On Wed, Sep 28, 2016 at 9:22 AM, 'Dominik Echterbruch' via doctrine-user < doctrine-user@googlegroups.com> wrote: > Thanks Marco. > > On Tuesday, September 27, 2016 at 11:57:13 PM UTC+2, Marco Pivetta wrote: >> >> Doctrine does not (and will not) support DEFA

Re: [doctrine-user] Free software ORM Designer program alternative to Skipper

2016-09-20 Thread Marco Pivetta
There's a metadata grapher in DocrtineORMmodule, but it's not really a GUI. On 20 Sep 2016 16:52, "João Dalben" wrote: > Hello, I was wondering if there is a free software alternative to Skipper ( > https://www.skipper18.com/) to generate Doctrine 2 annotations? Even if > it

Re: [doctrine-user] Getting error

2016-09-07 Thread Marco Pivetta
Seems like an autoloading issue. Not related to doctrine, but to https://github.com/zendframework/ZendDeveloperTools Marco Pivetta http://twitter.com/Ocramius http://ocramius.github.com/ On Wed, Sep 7, 2016 at 4:13 PM, Nikhil Dhar <nikhildha...@gmail.com> wrote: > Hey I am new in th

Re: [doctrine-user] Doctrine ProxyGenerator issues a PHP warning when trying rename()

2016-08-16 Thread Marco Pivetta
You probably created proxies with one user, then tried to overwrite them with a different user. In general, at least for prod environments, you should ship with pre-generated proxy classes. Marco Pivetta http://twitter.com/Ocramius http://ocramius.github.com/ On Mon, Aug 15, 2016 at 7:50 PM

Re: [doctrine-user] PEAR support removed? Issue with pear.doctrine-project.org?

2016-08-03 Thread Marco Pivetta
, such as PHPUnit, for example, already shut down their PEAR repository ages ago. Heck, this is from 2014: http://marc.info/?l=php-internals=140056783816305=2 Cheers, Marco Pivetta http://twitter.com/Ocramius http://ocramius.github.com/ On Wed, Aug 3, 2016 at 4:23 PM, barryo <

Re: [doctrine-user] MySQL cache

2016-08-02 Thread Marco Pivetta
Usually, RDBMs are a poor fit as k/v cache. On 2 Aug 2016 7:58 a.m., "Nima Sadjadi" wrote: > Hi, > > What about this? Would consider to add? > > https://github.com/doctrine/cache/issues/175 > > Thanks, > > -- > You received this message because you are subscribed to the

Re: [doctrine-user] There is no column with name 'brand' on table 'customer', What??!!!

2016-07-12 Thread Marco Pivetta
transactional DDL, so you might be in some sort of limbo (neither pre- nor post- migration status) Marco Pivetta http://twitter.com/Ocramius http://ocramius.github.com/ On 12 July 2016 at 10:27, <juan.ango...@ofertix.com> wrote: > Yeah, soory I forget to iclude the schema: > &g

Re: [doctrine-user] There is no column with name 'brand' on table 'customer', What??!!!

2016-07-12 Thread Marco Pivetta
Not sure what is being asked: we don't know what your schema looks like before generating the migration... Marco Pivetta http://twitter.com/Ocramius http://ocramius.github.com/ On 12 July 2016 at 10:21, <juan.ango...@ofertix.com> wrote: > I'm getting this error when

Re: [doctrine-user] Tutorial clarification - ArrayCollection

2016-07-11 Thread Marco Pivetta
I linked the source file: https://github.com/doctrine/doctrine2/blob/master/docs/en/tutorials/getting-started.rst The docs are part of the doctrine2 sources. They get converted into website-version every once in a while. Marco Pivetta http://twitter.com/Ocramius http://ocramius.github.com

Re: [doctrine-user] Tutorial code differences vs. github

2016-07-11 Thread Marco Pivetta
Could you link the examples where you grabbed this from? Marco Pivetta http://twitter.com/Ocramius http://ocramius.github.com/ On 12 July 2016 at 07:00, Doctrinator <gregory.j.b...@gmail.com> wrote: > Hi Marco and others, > > There are differences between the tutorial's

Re: [doctrine-user] Tutorial clarification - ArrayCollection

2016-07-11 Thread Marco Pivetta
That seems good to me :-) Marco Pivetta http://twitter.com/Ocramius http://ocramius.github.com/ On 12 July 2016 at 06:40, Doctrinator <gregory.j.b...@gmail.com> wrote: > Thanks Marco! That makes a lot of sense. > > I'll be happy to do a PR, but perhaps getting the wor

Re: [doctrine-user] Tutorial clarification - ArrayCollection

2016-07-11 Thread Marco Pivetta
Hope that clarifies it. Please remember to edit the text on the documentation, if this was helpful and you now understand what is going on :-) Marco Pivetta http://twitter.com/Ocramius http://ocramius.github.com/ On 12 July 2016 at 02:20, Greg Bell <gregory.j.b...@gmail.com> wrote:

Re: [doctrine-user] Unit testing - memory leak problem

2016-07-10 Thread Marco Pivetta
It's a known problem. For now, run with php -dmemory_limit=2G ./vendor/bin/phpunit On 10 Jul 2016 12:54, "Marcin Drążek" wrote: > Hi Everyone, > I have a problem with unit testing. > When I run tests, it fails. See screenshot. > http://i.imgur.com/sAZrLui.png > > Is it

Re: [doctrine-user] Update custom type with new precision and scale not generating update script.

2016-07-07 Thread Marco Pivetta
This is kind-of a known limitation of DBAL types, sorry. See https://github.com/doctrine/dbal/issues/2411, for example. Also has been reported over multiple years, but it would need some architectural changes in DBAL that we didn't plan yet. Marco Pivetta http://twitter.com/Ocramius http

Re: [doctrine-user] Class Table Ineritance with specific join criteria?

2016-07-07 Thread Marco Pivetta
Hi Thales, No, the joining column would be the identifier, and the name would have to be the same on all joined tables. Marco Pivetta http://twitter.com/Ocramius http://ocramius.github.com/ On 7 July 2016 at 13:25, Thales Maciel <tvazmac...@gmail.com> wrote: > Hello, Marco! &

Re: [doctrine-user] Class Table Ineritance with specific join criteria?

2016-07-06 Thread Marco Pivetta
Hey Tales, No, the ORM won't be able to support what you want there. The current persisters/hydrators for JTI and STI structures require a discriminator column to be defined and populated with correct information. Marco Pivetta http://twitter.com/Ocramius http://ocramius.github.com/ On 7 July

  1   2   3   4   >