Cdr Postgresql write directly

Hi All,
can Asterisk write directly after a beginnig call in a Postgresql Database?
My configuration write in Postgresql after ending a call.
I need Data directly in my CRM.
Thanks Ronny

Asterisk can interact with DB (not only Postgre) at any point of dialplan execution. Read about func_odbc.conf. (search will give many links, for example this one: asterikast.com/_downloads/_docs/func_odbc.txt )

Thx for the quick answer. I installed odbc and connected it with postgresql.
I want the telephonenumbers of incoming and outgoing calls to be insert in postgresql database.
What do I have to add in extensions.conf and in func_odbc.conf?

[general]
static=yes
writeprotect=no


[buro]
;exten => 2000,1,Dial(SIP/2000)
;exten => _0[1-9].,1,Dial(SIP/${EXTEN}@364433-ext-sip)
exten => _0.,1,Dial,SIP/${EXTEN}@364433-ext-sip|45|r

[werkstatt]
exten => _0.,1,Dial,SIP/${EXTEN}@364434-ext-sip|45|r

[von-voip-provider19]
exten => 49xxx,1,Dial(SIP/2000)

[von-voip-provider33]
exten => 49xxx,1,Dial(SIP/2000)

[von-voip-provider34]
exten => 49xxx,1,Dial(SIP/2001)

greatings ronny