Set WeberTrivia.com to be my default homepage.   Suggest a Question                                               

Suggest A Question : :  Frequently Asked Questions : :  Search : :  Relevant Manuals : : 
PHP Questions : :  Linux Questions : :  MySQL Questions : : 
home  [ Login ] 

SPI_saveplan

Name

SPI_saveplan -- save a plan

Synopsis

void * SPI_saveplan(void * plan)

Description

SPI_saveplan saves a passed plan (prepared by SPI_prepare) in memory protected from freeing by SPI_finish and by the transaction manager and returns a pointer to the saved plan. This gives you the ability to reuse prepared plans in the subsequent invocations of your procedure in the current session. You may save the pointer returned in a local variable. Always check if this pointer is NULL or not either when preparing a plan or using an already prepared plan in SPI_execp.

Arguments

void * plan

the plan to be saved

Return Value

Pointer to the saved plan; NULL if unsuccessful. On error, SPI_result is set thus:

SPI_ERROR_ARGUMENT

if plan is NULL

SPI_ERROR_UNCONNECTED

if called from an unconnected procedure

Notes

If one of the objects (a table, function, etc.) referenced by the prepared plan is dropped during the session then the results of SPI_execp for this plan will be unpredictable.

Who's Online
Guest Users: 13
Google
Web
WeberTrivia
WeberDev
WeberForums
 Free Sample Chapters  Free Sample Chapters
  Deliver First Class Web Sites: 101 Essential Checklists
Want to learn how to make your web sites usable and accessible? Want to ensure that your sites meet current best practice, without spending hours trawling through incomprehensible specifications and recommendations from dozens of different books, research papers, and web sites? Want to make sure that the sites you build are "right the first time," requiring no costly redevelopments?

More Sample Chapters

PHP General