AI Zone Admin Forum Add your forum

NEWS: Chatbots.org survey on 3000 US and UK consumers shows it is time for chatbot integration in customer service!read more..

How to connect LinuxChatScriptpg64 to PostgreSQL on AWS RDS service? 
 
 

Hello

I would appreciate any help with using PostgreSQL on AWS RDS with ChatScript.

I am running ChatScript on EC2 server and I can run ./LinuxChatScript64 that came precompiled in the downloadable package and connect to PHP chat script served by apache2 (all on Ubuntu 14.04 x64).

I have also started PostgreSQL database on RDS and would like to use LinuxChatScriptpg64 - any ideas how to pass DB parameters (endpoint, master username and password) to make it work?

Many thanks

Arek

 

 
  [ # 1 ]

There is a postgres chatbot that ships with CS in the RAWDATA/POSTGRES folder. It illustrates connection to a server like this in simpletopic.top:


u: (open)  if (^dbinit( dbname = postgres port = 5432 user = postgres password = somepassword )) {db opened}
    else {dbinit failed - $$db_error}

 

 
  [ # 2 ]

Thanks Bruce, thats a great start for me! Any idea how wuld I pass endpoint (hostname) to the database as its not local?

Many thanks indeed

Arek

 

 
  [ # 3 ]

CS calls the postgres api: PQconnectdb- see: http://www.postgresql.org/docs/8.1/static/libpq.html#LIBPQ-CONNECT

 

 
  [ # 4 ]

PostgreSQL 8.1 is a very old version and unless you have a particular reason for referring to that version, the current version 9.4 is a much better choice.

http://www.postgresql.org/docs/current/static/libpq-connect.html

 

 
  [ # 5 ]

same api.  I have no particular concerns over which version

 

 
  login or register to react