Site's Queries Seem to Change On Their Own?

This site has operated perfectly 2018, and then recently the database queries began to fail. When I started investigating, I found the databases with joins were failing due to some reason aliases were added on their own. As this happened, the queries began to fail.

What would cause this to happen inside a site that is this old? I believe the site was built with Wappler 3? I only ask so that I can be aware of the cause and hopefully prevent any further occurrence of this bazaar behavior – if that is possible.

It appears the app started adding aliases to the join queries all by it self. It seemed to replace the aliases that I had assigned. When I found the occurrences, the app seemed to replace existing aliases with ‘undefined’. Once began to happen, of course, the queries started failing. What’s weird is it was all working for years and then for some reason something triggered all these queries to add “UNDEFINED” aliases throughout the site.

This type of activity has popped up throughout the queries of the database. As I alluded to, it seems that activity started around several months or so ago.

If you have any ideas or suggestions of how I can prevent this from happening again, your help is very welcomed and very appreciated!

I suppose it is a php project…

Maybe it has to do with php version on your server?
You updated wappler and some db operations don’t work with the current php version
That’s the first thing comes to my mind…

You may have something there. Yes it is a php project. A very large one. Ha!

I never imagined that something like this would happen. It seems this host goes through this process every couple of years.

I guess I will have to pass through each of these queries and rewrite them? Oh boy… can’t wait!

Any ideas of how I can remedy this as fast as possible? Ha!
Maybe I can assign it to ChatGPT… Ha!

I wouldn’t change anything in my project if this has happened to me. I would try to find what change was made on my hosting provider environment.
I don’t know if you could just try localy your project by rolling back a few versions of php version…
What php version does your hosting enviroment run with now? Can you create a loacl server and try previous verionns?

I have MAMP Pro. I don’t have a lot of experience using it however.

So I could request that the host (Bluehost) downgrade our php version on this site?

I may just, as you say, setup the local server and peruse through the versions I have and see what works out.

1 Like

What you can do @revjrblack is change the php version until you find the one that works for your site again.

and then…start the process of upgrading the queries locally for the unavoidable upgrade that you will be forced to do at some point.

I disagree this is related to a PHP version, PHP version changes don’t mutate your app files. How are you seeing changes in your database queries in Wappler editor? This is probably something that got broken with a Wappler update

Another site bit the dust as well. Please note that the error message contains the statement: :$server is deprecated"

I guess it’s time to do some house cleaning.

{“code”:0,“file”:"/home1/blaxstud/public_html/",“line”:37,“message”:“Creation of dynamic property lib\core\Request::$server is deprecated”,“trace”:"#0 /home1/blaxstud/public_html/ exception_error_handler(8192, ‘Creation of dyn…’, ‘/home1/blaxstud…’, 37)\n#1 /home1/blaxstud/public_html/ lib\core\Request->__construct(Object(lib\App))\n#2 /home1/blaxstud/public_html/ lib\App->__construct()\n#3 {main}"}

Both. Online and in Wappler. However, these sites have been active from 2016. Of course I’ve updated them as time passed. There must have been a huge change for them to just go loco. Deputation.US will not even allow a login. Ha!

Oh well… time to get to work.

Do you use Git? (for “backup” purposes)

I am having a hard time finding how your host could have caused this. If files on your local machine are changed as well.

From briefly reading this, I have a feeling it’s two separate issues:

The first being the PHP version changed on the server, which caused some kind of issue with queries or something similar of that nature because a feature was deprecated in the newest release. This post says at the time 5.6 was what most of the code was for. If the site hasn’t been touched since 3.0, it probably didn’t receive the later compatibility updates (if there were any?) for later PHP versions.

And then second being since it was mentioned the site was built in Wappler 3, and assuming the project hadn’t been opened in Wappler 4 or 5, I wonder if loading the project up in 6 after last being edited in 3 caused a second separate issue which caused is causing the undefined aliases. I’m pretty sure I only used Wappler 3 for a few weeks, but I vaguely remember having a similar issue in the past with one of my projects (Might’ve have been 3 to 5?)

Chances are, if the files haven’t been changed on the server, reverting to an older PHP version would fix it.


From memory, some php functions need version 7.4 minimum to function correctly due to some changes made around late V4.
I have been using V8+ without issues.

1 Like

I’ve not switch as yet to version 6. If switching would help cure this, I game.

However, I just want to know how the easiest way to correct these errors that are popping up on all our older projects.

A lot of queries are now broken. This is what I find to be the usual result:

I am not certain of who or what caused it. However, Bluehost migrated a lot of our older projects shortly after COVID (Ha!). Nevertheless, the connectivity was broken while they messed up all our projects. I had to get extra domains and mirror the projects to keep the clients happy. It was a nightmare.

However, Bluehost was the cause.

I think this issue is different however.