I have a problem in PHP. When more than one client update something in database, they won't work.
so, how do I make out for it?
example: at the same time, in real-time chatboard, 2 persons click CHAT, what can I do so that both of them actually chat? or at bidding website, when 2 persons bid at same time, how could I do that?
Actually You can build Transactions before update or inserting data into database. also don't work with out proper primary and foreign keys in you tables. Try to use autogenerate option for primary keys.
I suppose you are using mysql database, I dont know about mysql transactions, but I use oracle 10g.
If I have to execute set of 2 query in the manner that 2 should succeed or no query should execute.
CODE
$query1="some insert";
$statement1 = oci_parse($connection, $query1); if ((oci_execute($statement1,OCI_DEFAULT))) {
[indent] $query2="some more insert"; $statement2 = oci_parse($connection, $query2); if ((oci_execute($statement2,OCI_DEFAULT))) [indent] oci_commit($connection)); [/indent]
Ok, so I'm making some arcade administration software so I don't have to add games the hard
way, well anyway, one of the features I have is that on the homepage is a featured author and as
such I just have it so it updates one line in the mySQL. Well, the page with the form passes on the
varibles fine and the updating page recieves them because I echoed everything, then I build the
query and I even echo the query and it comes out exactly how I want it to, but for some reason, the
database itself won't update even though all the varibles are there. Here's....
Hey guys, I'm currently making my own online PHP game, and I'm smack into the middle of the
coding. The game is an industry/economy type game where you start out with some initial resources
and a building and you expand your business empire by building more buildings that produce more
buildings, which can be bought and sold on the live market. Basically, you try and become the
wealthiest player in the game by the time the round ends. My problem is, I need my game to update
hourly and not hourly. Meaning, I have codes that update my MySQL database when a user bu....
i need to make a script that will take a number from every record in a mysql table, takeaway 1 from
them all then replace them all in the right places. so if it looked like Record 1 5 Record 2 8
Record 3 9 then i exectue the script then it turns into: Record 1 4 Record 2 7 Record 3 8 i
cant think of a way to do this so if you can help id be very greatful. Thanks in advance Andre....
Looking for concurrency, problem, update, time
*RANDOM STUFF*
*SIMILAR VIDEOS*
Searching Video's for concurrency, problem, update, time
Express your Opinions, Thoughts or Contribute your information that might help someone here.
Ask your Doubts & Queries to get answers.. "Together, We enlight each other!"
Register FREE for AD-FREE
forum, Create your own topics, Ask Questions, track topics, setup
subscriptions & notifications and Get a Free Website w/ Email and FTP.