Is there no one to help me in this community? I need help upgrading my site

Abayomi Oladipupo Posted in Technical Support 9 years ago

Please I am having a little problem about my site, in the course of self manual upgrading, i deleted some files, and it caused a great damage to the site, and now i have found a place where seems to be contain some of the files, but how do i reconfigure it?
Secondly, if user want to edit their profile, they will edit it but will trigger the following message when they want to save it.

"{A system error has occurred. Please try again later. You may email the details of this error to the system administrator at [email protected].
exception "OssnDatabaseException" with message "Unknown column "location" in "field list" UPDATE ossn_users SET `first_name` = "System",`last_name` = "Administrator",`email` = "[email protected]",`location` = "Location Country" WHERE guid="1" " in /home/facemech/public_html/classes/OssnDatabase.php:77 Stack trace: #0 /home/facemech/public_html/classes/OssnDatabase.php(120): OssnDatabase->execute() #1 /home/facemech/public_html/components/OssnProfile/actions/edit.php(103): OssnDatabase->update(Array) #2 /home/facemech/public_html/libraries/ossn.lib.actions.php(51): include_once("/home/facemech/...") #3 /home/facemech/public_html/system/handlers/actions.php(12): ossn_action("profile/edit") #4 {main}  -]"

Can someone mail me to [email protected] if there is any help you can do for me, as i dont know the next step to take anymore
Thank You.

Replies
ng Abayomi Oladipupo Replied 9 years ago

As you can see, the database need to have following field, lives at, works at, studied _____, relationship status, , but it doesn't, and if you add location, it will not save the location, save only the age

And how can I add the following field to database, , lives at {location in country name} working at {companyname}, studied {disciplinename }at {school_name} in relationship with either {boy or girl name} etc

I believed these has to be included in the database, but how do I do that?

Or can someone develop a component that will do such work, it is very essential, as you cannot add those this I added by the left column of my site without the verified account component, now can we have a component that will work in hand with verified account component which will make it easier for added field to be included, editable by users, saved and included in users profile,

German Michael Zülsdorff Replied 9 years ago

Yes, I said I give up. That's correct.
And all that I'm reading here lately does only confirm: I was damned right.

Abayomi, still insisting on running his site with those weird hacks included - no discussion.
Then David, still convinced that a database is running berserk if you don't make use of every available column. Yeah, I'm already a little afraid to receive a mail from my database like "Zet, either you add at least 10 new users a day, or I swear I'll fuck up! Come on, call me, update me."

ng Abayomi Oladipupo Replied 9 years ago

Anyway, I removed this 'location' from the file /home/facemech/public_html/components/OssnProfile/actions/edit.php in line 52 and this $user["location"] from the same file ``/home/facemech/public_html/components/OssnProfile/actions/edit.php` in line 58 of the same file all not on SQL and it works back as normal, but now how can i make the user profile to include the work status, lives in and studied sososo and relationship status to be edited and saved in the user profile?

Thank you.

Indonesian Arsalan Shah Replied 9 years ago

> PS - Arsalan... you want me to be constructive, but when I try to help
> anyone here.

That is why i said 'David and All other members' , i am not only mentioning you, never mind.

(-_-) ------ really ? lol
/ \/

Indonesian Arsalan Shah Replied 9 years ago

> isn't that what I said, like... three posts ago... all the way up
> until now?
>
> Look... I know I don't speak the lingo as well as you do, but
> everything you are saying is what I was trying to say.

I didn't said that you haven't replied the same. I appreciate your help David. But i am trying to tell him why this appear and why it shouldn't appear.

> I'm telling you, there's a duplicate entry in SQL that has an extra "Location" field added. I'll bet my grandmother and her doggie on it. He can't just restore the core files... he needs to check his SQL as well, and make sure that field is gone.

I am not sure, but as far i am developer that error he posted is clear that location field is not found in database , but i have few questions:

  • Why error triggered ?
  • Who is trying to look up for location field ?

Simply the error triggered because there is php code that is trying to find location field in database and when it didn't found OssnDatabase Exception throws the error that you are looking for something in database that is not really present. So how he can remove something that really isn't present. In other words there is no duplicate entry.

Now i am trying to win your grandmother doggie But if you send me cat that would also be fine.

Indonesian Arsalan Shah Replied 9 years ago

> David, I can't Stop laughing oooooo

I also can't stop laughing that you didn't followed the rules and finally busted, wow, but we are still trying to help you if you read those replies carefully you can fix the issue.

If you read https://www.opensource-socialnetwork.org/wiki/view/704/should-i-modify-core-files

You'll find out why we warned you about modifying core files.

> During the upgrade you'll lose all the changes you made.

ng Abayomi Oladipupo Replied 9 years ago

arsalan, all are just copy and paste,
if all those code are removed, it will work normal, but i want it to have those things which I set on it

ng Abayomi Oladipupo Replied 9 years ago

David, I can't Stop laughing oooooo

Indonesian Arsalan Shah Replied 9 years ago

@David

> This looks like a job for Zet Man!! Look!! Up In The Sky!! It's a
> bird!! It's a PLANE!! It's.... it's.... It's some smart dude with a
> LAPTOP!!!! It's ZET MAN!!!
>
> "HERE I COME TO SAVE THE DAYYYYYYYYYYYYYYYYYYY"
>
> He's all yours, Zet. :-) Have fun!!

David and all other members, Please keep the replies constructive. Its not a Job for Zet Man, its a mistake of Abayomi that we are trying to correct. Since he modified core files its not easy to solve his issue quickly.

As we said in docs

> Create a custom component and alter behavior through the Ossn component API.

If anyone don't know how to alter behavior please create a discussion about what he/she want to do.

Its clear that Abayomi didn't followed the measures and finally got issue. So tell me how we are supposed to help if someone didn't followed about what we said .

Indonesian Arsalan Shah Replied 9 years ago

> There's a column in SQL that needs to be removed... it's still looking
> for something that clearly isn't in the code. Or he added the field a
> second time when he reinstalled. Either way... the column needs to be
> removed from SQL, or it won't function.

Well what i understand form error is there is no column location in database, so how the column need to be removed from SQL?

I saw his files today as he sent request to support team, he modified the non-core components like aboutuser and added alot of other code. I think Paritosh helped him to modify core files and database.

Since this error is not originally caused by Ossn or non-core component we can't help you.

> Can't agree. The database is always the passive part. It's not "looking", it's being looked up. By the PHP code.

I agree with you, i am sure he added column before he reinstalled Ossn v3.7 and now he is using his modified version of aboutuser.

I always said don't modify core files.
https://www.opensource-socialnetwork.org/wiki/view/704/should-i-modify-core-files

To fix error please restore your all non-core components to original state.