3 Replies - 586 Views - Last Post: 27 January 2012 - 06:31 AM Rate Topic: -----

Topic Sponsor:

#1 arunpgs  Icon User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 3
  • Joined: 11-January 12

Help Regarding Asp.Net Project

Posted 25 January 2012 - 10:15 PM

Hi!

I want to execute the sql query based on the question. For Example, In Textbox If i enter the question like "What are the department in allahabaduniversity" means following query will be executed "select department from allahabaduniversity;" , Here department is a filed and allahabaduniversity is table,

Please Help Me to do this...

Thanks!

Regards!

G.Arun Prasath

Is This A Good Question/Topic? 0
  • +

Replies To: Help Regarding Asp.Net Project

#2 Blasterman007  Icon User is offline

  • New D.I.C Head

Reputation: 2
  • View blog
  • Posts: 25
  • Joined: 15-September 09

Re: Help Regarding Asp.Net Project

Posted 26 January 2012 - 10:21 AM

I think we need more information than you provided.

Are the questions from an text box or select? In other words, are you allowing the clients to type in whatever question they want or do they have to select a specific question from a list?

From a specific list, you can pre-determine query design for each question and maybe use a select case to execute the proper query.

If working off free form text, you need some serious coding and exception processing. What if they mispsell the university name, type professors instead of departments, don't name the departments to match exactly your fields. You would need to trap for questions that failed to yield results and tweak your code to respond accordingly in the future. It will get better over time but you are looking at a lot of work and constant maintenance.

I think you get the idea. If you can provide more information about what you are doing and possibly a page design, someone might be able to point you in the right direction.
Was This Post Helpful? 1
  • +
  • -

#3 arunpgs  Icon User is offline

  • New D.I.C Head

Reputation: 0
  • View blog
  • Posts: 3
  • Joined: 11-January 12

Re: Help Regarding Asp.Net Project

Posted 26 January 2012 - 10:50 PM

Thanks for Your Reply.....now what i want to do is if user type questions in textbox means in background particular sql query will be executed and result will be displayed in grid view
Was This Post Helpful? 0
  • +
  • -

#4 Blasterman007  Icon User is offline

  • New D.I.C Head

Reputation: 2
  • View blog
  • Posts: 25
  • Joined: 15-September 09

Re: Help Regarding Asp.Net Project

Posted 27 January 2012 - 06:31 AM

Wow - I think you are going to be in need of more than a single post on a forum for this one.

You will need a lot of code to do things like:
1) Parse string into key words
2) Compare to tables of keywords for spelling variations (i.e. Center, Centre, Department, Dep, Dept, etc) due to misspelling, abbreviation or cultural differences
3) Build logic to match key words to specific tables
4) Build logic to determine fields needed from table to respond to question
5) Build logic to prompt for more information if any of the above fails or simply say "I don't understand"
6) Log occurances of failures so you can tweak logic to respond better in future

Most search engines for web, tech support, etc. use simpler approaches by basically taking your key words and using in WHERE statements from a single source. You wanting to open and query specific tables based on wording in the question almost borders on AI programming.

I personally would take some time to really scope out your project in detail. Why using multiple tables to respond to questions? Is there an easier way? Can I walk a client to a finer area in the site like Departments and then let them ask a question? This way they are in the dept table and question could go to where statement. Hope this makes sense. Good Luck.
Was This Post Helpful? 0
  • +
  • -

Page 1 of 1