Support A2Billing :

provided by Star2Billing S.L.

Support A2Billing :
It is currently Tue Apr 16, 2024 7:06 pm
Voice Broadcast System


All times are UTC




Post new topic Reply to topic  [ 3 posts ] 
Author Message
 Post subject: Problem with Postgresql 8.3
PostPosted: Sun Jul 20, 2008 8:38 am 
Offline

Joined: Sun Jul 20, 2008 8:15 am
Posts: 1
Hi!
On the old server billing work good (psql 8.2.X). But when I install billing to new server with Postgresql 8.3, I see this error in debug console of *:

Code:
a2billing.php|1: file:Class.A2Billing.php - line:701 - DESTINATION ::> 38044XXXXXXX
  a2billing.php|1: file:Class.A2Billing.php - line:703 - RULES APPLY ON DESTINATION ::> 38044XXXXXXX
  a2billing.php|1: file:Class.A2Billing.php - line:739 - ERROR ::> RateEngine didnt succeed to match the dialed number over the ratecard (Please check : id the ratecard is well create ; if the removeInter_Prefix is set according to your prefix in the ratecard ; if you hooked the ratecard to the Call Plan)
    -- Playing 'prepaid-dest-unreachable' (escape_digits=#) (sample_offset 0)
  a2billing.php|1: file:Class.A2Billing.php - line:654 - [CARD STATUS UPDATE : UPDATE cc_card SET inuse=inuse-1 WHERE username='50410']
    -- AGI Script a2billing.php completed, returning -1


All callplans & ratecards is OK.

In postgres log I see:

Code:
ERROR:  функция length(timestamp without time zone) не существует на символе 2120
ПОДСКАЗКА:  No function matches the given name and argument types. You might need to add explicit type casts.
КОМАНДА:  SELECT
                        tariffgroupname, lcrtype, idtariffgroup, cc_tariffgroup_plan.idtariffplan, tariffname, destination,
....


I think what this problem is linked to new syntax psql.

What I can do?
Return to Postgres 8.2 is very hard for me.
Please help.


Top
 Profile  
 
 Post subject:
PostPosted: Sat Jul 26, 2008 5:43 pm 
Offline
Moderator
User avatar

Joined: Thu Jun 22, 2006 2:19 pm
Posts: 2890
Location: Devon, UK
I don't have Pg8.3 available to test with currently, but I think I can see the problem. Try modifying Class.RateEngine.php on lines 176-177:
Code:
      AND startingdate<= CURRENT_TIMESTAMP AND (expirationdate > CURRENT_TIMESTAMP OR expirationdate IS NULL OR LENGTH(expirationdate::text)<5)
      AND startdate<= CURRENT_TIMESTAMP AND (stopdate > CURRENT_TIMESTAMP OR stopdate IS NULL OR LENGTH(stopdate::text)<5)
      $sql_clause_days
That is to say add an explicit cast to the 'text' type within each of the LENGTH() clauses.
I've not tried this so it might not fix your problem.


Top
 Profile  
 
 Post subject: javascript:emoticon(':!:')
PostPosted: Fri Aug 01, 2008 4:37 pm 
Offline

Joined: Fri Aug 01, 2008 4:32 pm
Posts: 1
Your "::text" worked immediatily. Thanks.

Added after 2 minutes:

immediately, of course.


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 3 posts ] 
Voice Broadcast System


All times are UTC


Who is online

Users browsing this forum: No registered users and 4 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group