+ 2
insert data in two different databases using ajax
Does anyone knows how to insert data in two different databases at the same time using ajax? In add form there is multiple data that needs to be filled but they are splited in two different databases, so when I press add button it should save data in both databases.
7 Antworten
+ 1
Two different databases or two different tables in database?
+ 1
two different databases
+ 1
Eric Kazhus
You can make two different connection for each database.
+ 1
Already have done that! I have 2 insert into functions too that should save data in one database and other data in second database, but I think problem is in ajax/javascript code part that I have. thought if there is some kind of example which to follow because couldnt find anything useful in internet.
0
Eric Kazhus
Check these links and tell if you face any problem
https://codingstatus.com/how-to-insert-data-using-ajax-in-php/
https://steemit.com/utopian-io/@sogata/how-to-insert-data-to-mysql-from-php-using-jquery-ajax
0
We can do this without ajax also
In jdbc i will create 2 methods
Method 1 is working with oracle
Method 2 is working with mysql
Passing data will be depend upon tablename and fields available in database
0
Method 2 is working with mysql
Can You provide an example please?