开发者

Get all parameters from a doctrinemongodb document

I'm working with Doctrine 2.0 MongoDB/Symfony 2 and I asked myself if t开发者_StackOverflowhere is some way to get all parameters from a document. For example: document User has: username, mail, gender. I'm looking for a function that returns "username", "mail", "gender".


When you make a query with Doctrine ODM with: createQueryBuilder, find, findAll and so on, you obtain a whole result with all the fields. In your example, you can obtain its values through getters.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜