Forum OpenACS Q&A: Re: Error using __new function

Collapse
Posted by Jun Yamog on
Hi Simon,

Its says that you may need to explicitly typecast it.  I had similar problem in content_item__new.  You will have to hunt down the offending parameter or typecast all.  What do I mean by that?  If the parameter for example that needs to be typecasted is subscription_id here is how you will call it:

select na_subscription__new(
                integer :subscription_id,
                :user_id,
                :feed_url,
                :host_url,
                :title,
                :description,
                '0',
                current_timestamp,
                'na_subscription',
                current_timestamp,
                :user_id,
                :peeraddr,
                :package_id
);

If explicitly typecasting it doesn't work... it must be another problem.  Hope this helps.