by

Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
  • Jul 03 13:52
    wollanup synchronize #1598
  • Jul 03 13:50
    wollanup synchronize #1598
  • Jul 03 13:49
    wollanup synchronize #1598
  • Jul 03 13:48
    wollanup synchronize #1598
  • Jul 03 13:28
    dereuromark closed #1192
  • Jul 03 13:28
    dereuromark commented #1192
  • Jul 03 13:27
    dereuromark labeled #1598
  • Jul 03 13:21
    wollanup opened #1598
  • Jul 03 13:11
    dereuromark commented #1192
  • Jul 03 13:09
    wollanup commented #1192
  • Jul 03 11:59
    dereuromark labeled #1406
  • Jul 03 11:52
    wollanup commented #1406
  • Jul 02 10:57
    Incognito edited #1596
  • Jul 02 10:56
    Incognito opened #1597
  • Jul 02 10:55
    Incognito opened #1596
  • Jul 02 10:23

    dereuromark on master

    FIX bug CLOB_EMU oracle Merge branch 'patch-1' fix php version and 2 more (compare)

  • Jul 02 10:23
    dereuromark closed #1593
  • Jul 02 07:50
    Incognito synchronize #1595
  • Jul 02 07:34
    Incognito synchronize #1595
  • Jul 02 06:54
    mruoss synchronize #1470
Crobitaille
@Crobitaille
(I use toArray() on it to change the return into an array. but without that call... its an object)
Marc J. Schmidt
@marcj
A plain array? That's not possible, findOne has no code to return an Array. You might have overritten something
Crobitaille
@Crobitaille
I haven't modified any of the propel code.
Marc J. Schmidt
@marcj
it also doesnt make sense for toArray() to not return an array but an entity object. I guess there is some code that confuses them. Try to put the critical parts in a reproduceable git repo, then we can try to help
I dont mean propel code, but maybe code in query classes
does your permissions object have only ine column, or an array column?
Crobitaille
@Crobitaille

Yeah that's what I mean, I havent modified the query classes.

No it has 3 columns: id, scenarioName, connectionName.

Unfortunately putting the code in a reproducible manner into a repo isn't possible.
Crobitaille
@Crobitaille
It's fine. I just wanted to know if it was intended behaviour or not. Since it's not I'll just work around it.
not much else I can do. Thanks for the help.
Urs Hofer
@urshofer
trying to do something like this with propel, having a very hard time... Is there a documentation for sub selects somwhere?
    SELECT   *  FROM _contributions as c   
    WHERE
            c._name = 'BLABLA'
            AND c.id IN (SELECT d._forcontribution FROM _data as d WHERE
                (d._fortemplatefield = 11 AND d._content LIKE '%3%')
                OR (d._fortemplatefield = 13 AND d._content LIKE '%5%')
                OR (d._fortemplatefield = 15 AND d._content LIKE '%7%')
                OR (d._fortemplatefield = 18 AND d._content LIKE '%4%')
                OR (d._fortemplatefield = 19 AND d._content LIKE '%1445%')
            )
Urs Hofer
@urshofer
…hm, okay, probably doing sthing like:
$q->where('_contributions.id IN (SELECT d._forcontribution FROM _data as d WHERE (d._fortemplatefield = ? AND d._content LIKE ?))', [15, '%3%']);
Lioxor64
@lioxor64

Hello, my name is Liora and I am currently hunting open source projects for company NeuraLegion (www.neuralegion.com)
We just launched a free annual subscription for open source projects for our AIAST tool NexPloit.

If you are interested, please, reach us on opensource@neuralegion.com!

Thank you for your time and consideration! If you have any questions, please do not hesitate to contact us!

Best,

Kev
@kev-leitch
New to Propel - how would I convert this SQL query into Propel syntax? SELECT COUNT(distinct User_Id) AS DistinctIDs FROM Tbl_User_Answers
bkh
@bkh2js
In ConnectionFactory.php line 43:

  Unable to open connection  


In PdoAdapter.php line 72:

  Unable to open PDO connection  


In PdoConnection.php line 59:

  could not find driver
Hi anyone has this error when generate classes?
Jesse Quinn
@jessequinn
hi guys, quick question, I have recently upgraded from 1.6.4 to 2, and i am trying to wrap my head around some of the changes. Normally i would use a doSelectOne($c); on a criteria, but this no longer works with v2. how can i use a criteria within a query based class?
Alberto Castillo G.
@acastillors_gitlab
Hi, is there a way to get all TableMaps from Propel? I know \Propel::getDatabaseMap() will only load runtime (so previously loaded tables). My goal is to be able to get properties for every model, more specifically create \ReflectionClass from them.
Federico
@pmfederico
I just tried propel2 on PHP 7.4, many errors come up, they are mostly warnings, however there some fatal which are for instance, the use of the parent keyword on a class without a parent
Does anyone know if PR's are still accepted for propel 2
petr zeman
@perseusssss_twitter
I have probably a very dumb question. I have propel installed and managed to successfully reverse-engineer my database so it is working. However whenever I try to start propel init it just keeps getting automatically aborted and I have no idea why. Any tips?
image.png
petr zeman
@perseusssss_twitter
nvm, retarded powershell
Nithrild
@Nithrild
Hello guys! I have a question. You see, I have a site hosted in a shared hosting service. I was already told that I cannot have SSH in my current plan, so I can run things like migrations. My question is: Is there any way to run the migration (or any PROPEL commands) from a .php file? I've been doing some research and for example, for Laravel there's a way to do this, but I'd like to do it with PROPEL. Thanks!
Federico
@pmfederico
@Nithrild Open the command file and add that to a php file, easy, also any hosting that doesn't lets you run command line is utter bullshit
But that seems to be a common rule in Germany
Switch to digital ocean
Nithrild
@Nithrild
@pmfederico Thank you for the answer. I have a question about that though. I cannot find a Command file. I don't really understand how to call the "propel diff", "propel migrate" commands from a file. Can you give me an example of how to do this?
Federico
@pmfederico
@Nithrild how do you run your migrations now?
Nithrild
@Nithrild
On my local computer, I open the console, and in the directory of my project I type the "propel diff" command. This creates the migration file, and then I run the "propel migrate" command. I want to be able to run these commands from a .php file so I can update my production database
Nithrild
@Nithrild
Thank you, @pmfederico . I was able to run the command
Federico
@pmfederico
np
J Skoba
@SpikedCola
hi all! quick question, hopefully there's an easy solution. i'm attempting to "lock out" the changing/updating of certain columns for my model. ideally this would happen in the setXXX() functions (if condition is true, return without making a change). however it looks like there's no hook in the setXXX functions, like there is for preInsert/preUpdate/etc. i tried _call and _set magic functions, but they don't seem to be triggered since the setXXX function exists. i could override each of the setXXX() functions myself, but if the db schema changes i will have to manually fix the overrides. a) does this make any sense, and b) does anyone see a way to accomplish this?
is there perhaps a way to insert code into propel's build process, so i could add my own function/hook when setXXX is generated?
J Skoba
@SpikedCola
i've overridden isColumnModified and that got me half-way there. i can prevent inserting/updating the columns of interest by returning false. however the object's value can still be changed, which could lead to confusion..
Adrian Padurean
@Securiteru_gitlab
Hey! Quick question, does any1 know if there's SQL query results caching in propel or what would be the best solution for that? Thanks.
Ryan Rentfro
@SourceCode
For caching use redis or elasticache (AWS redis) with a TTL. The best way to do that is to store the query results by hash. So if a query has been ran in the TTL window it will just pull the cache result vs going to the database itself.
Just a heads up - some symfony stuff seems to break with the latest packages of propel + symfony config/finder/filesytem - thinking its config - stackoverflow details here: https://stackoverflow.com/questions/62280493/fail-to-run-propel-command
Adrian - you can also write a behavior that can do that automatically if its a pattern you need to use all over the place.
Ryan Rentfro
@SourceCode
Rolling back the 3 packages I highlighted in Stackoverflow fixed the issues in that thread btw.
all of them back to v3.4.22
Adrian Padurean
@Securiteru_gitlab

Adrian - you can also write a behavior that can do that automatically if its a pattern you need to use all over the place.

I'm already on that path, I'm using Redis and I'm trying to integrate a new behaviour. Can you suggest a propel2 guide in order to achieve this?

Thank you for the feedback!
Ryan Rentfro
@SourceCode
http://propelorm.org/documentation/06-behaviors.html - check this out - use a pre and post hook, what you want to do is a have a check method for redis cache in pre and in post you want to write if you ended up doing a read (or whatever it is you are wanting to cache).
The user contributed provide some great examples as well: http://propelorm.org/documentation/cookbook/user-contributed-behaviors.html
Another thing to consider (based on what you are trying to accomplish) is that you can also cache things client side in a browser via local storage.
We do that for things like a menu that has items with "previously visited items" - we don't care to store that, but the user finds it helpful
Denis Turkov
@PhilinTv
Hello everyone,
Propel2 like a Phoenix got the first release in recent years with PHP7.4 and Symfony5 support.
https://github.com/propelorm/Propel2/releases/tag/2.0.0-alpha9
http://propelorm.org/blog/2020/06/25/propel2-alpha-9-is-released.html
In case of any compatibility troubles, you know what to do https://github.com/propelorm/Propel2/issues/new
:)
Daniel Rose
@daniel-rose
Hello everyone,
how can i add a subquery to a where clause?
J Skoba
@SpikedCola
Hi all, i'm trying to override the mapping between Propel types and native SQL types, per the section at the bottom of http://propelorm.org/documentation/10-configuration.html
When I try and specify the new class to be used
propel.platform.class = propel.engine.platform.${propel.database}Platform
I subsequently get an error when running propel build: Unrecognized option "platform" under "propel". Available options are "database", "exclude_tables", "general", "gene
rator", "migrations", "paths", "reverse", "runtime".
J Skoba
@SpikedCola
so i think the correct key is propel.generator.platformClass .. filed an issue on github so docs can be updated. ty for the great orm!