Welcome to the Question2Answer Q&A. There's also a demo if you just want to try it out.

How do I prevent multiple insert of same Question into qa DB, when running the PHP script in small intervals of time.

+1 vote
1,453 views
asked Jul 11, 2013 in Q2A Core by Amith
I have developed an application in PHP which I get questions from YQL DB , dump it to a .json file then read the file and upload the questions to QA DB.

 

I use "qa_question_create()" to insert questions into DB.Problem I am facing is: when I run the program in small interval of time, Same questions will be inserted into DB again and again.

 

How do I prevent multiple insert of same Question into qa DB, when running the PHP script in small intervals of time.
commented Jul 11, 2013 by Scott
Can't you just keep track of which ones you already added?
commented Jul 11, 2013 by amithraj1989
Have done it with some tweaks to the inbuilt functions and files.
 I have a small doubt now.

How do I change the HTML part of this app?

I need to add a button to the page which triggers the php that I have written to load the DB with questions.

Please log in or register to answer this question.

...