pdf viewer dll for c# : Add picture to pdf form SDK control service wpf web page azure dnn postgresql-9.4-A4125-part2752

SPI_copytuple
Name
SPI_copytuple—makeacopyofarowintheupperexecutorcontext
Synopsis
HeapTuple SPI_copytuple(HeapTuple
row
)
Description
SPI_copytuple
makes a copy ofa rowin the upperexecutor context.This is normallyused to
return a modified row from a trigger. In a function declared to return a composite type, use
SPI_returntuple
instead.
Arguments
HeapTuple
row
rowtobecopied
Return Value
thecopiedrow;
NULL
onlyif
tuple
is
NULL
1178
Add picture to pdf form - insert images into PDF in C#.net, ASP.NET, MVC, Ajax, WinForms, WPF
Sample C# code to add image, picture, logo or digital photo into PDF document page using PDF page editor control
add photo to pdf reader; how to add an image to a pdf in preview
Add picture to pdf form - VB.NET PDF insert image library: insert images into PDF in vb.net, ASP.NET, MVC, Ajax, WinForms, WPF
Guide VB.NET Programmers How to Add Images in PDF Document
add image in pdf using java; pdf insert image
SPI_returntuple
Name
SPI_returntuple—preparetoreturnatupleasaDatum
Synopsis
HeapTupleHeader SPI_returntuple(HeapTuple
row
, TupleDesc
rowdesc
)
Description
SPI_returntuple
makesacopyofarowintheupperexecutorcontext,returningitintheformof
arowtype
Datum
.Thereturnedpointerneedonlybe convertedto
Datum
via
PointerGetDatum
beforereturning.
Notethatthisshouldbeusedforfunctionsthataredeclaredtoreturncompositetypes.Itisnotused
fortriggers;use
SPI_copytuple
forreturningamodifiedrowinatrigger.
Arguments
HeapTuple
row
rowtobecopied
TupleDesc
rowdesc
descriptorforrow(passthesamedescriptoreachtimeformosteffectivecaching)
Return Value
HeapTupleHeader
pointingtocopiedrow;
NULL
onlyif
row
or
rowdesc
is
NULL
1179
VB.NET Image: Image Cropping SDK to Cut Out Image, Picture and
VB.NET image cropping method to crop picture / photo; size of created cropped image file, add antique effect Public Partial Class Form1 Inherits Form Public Sub
add picture to pdf in preview; add image field to pdf form
VB.NET Image: Image Scaling SDK to Scale Picture / Photo
VB.NET DLLs to Scale Image / Picture. There are two this VB.NET image scaling control add-on, we RE__Test Public Partial Class Form1 Inherits Form Public Sub New
adding a jpeg to a pdf; add photo pdf
SPI_modifytuple
Name
SPI_modifytuple—createarowbyreplacingselectedfieldsofagivenrow
Synopsis
HeapTuple SPI_modifytuple(Relation
rel
, HeapTuple
row
, int
ncols
,
int
colnum
, Datum
values
, const char
nulls
)
Description
SPI_modifytuple
createsanewrowbysubstitutingnewvaluesforselectedcolumns,copyingthe
originalrow’scolumnsatotherpositions.Theinputrowisnotmodified.
Arguments
Relation
rel
Usedonlyasthesourceoftherowdescriptorfortherow.(Passingarelationratherthanarow
descriptorisamisfeature.)
HeapTuple
row
rowtobemodified
int
ncols
numberofcolumnstobechanged
int
colnum
anarrayoflength
ncols
,containingthenumbersofthecolumnsthataretobechanged(column
numbersstartat1)
Datum
values
anarrayoflength
ncols
,containingthenewvaluesforthespecifiedcolumns
const char
nulls
anarrayoflength
ncols
,describingwhichnewvaluesarenull
If
nulls
is
NULL
then
SPI_modifytuple
assumesthatnonewvaluesarenull.Otherwise,each
entryofthe
nulls
arrayshouldbe
’ ’
ifthecorrespondingnewvalueisnon-null,or
’n’
ifthe
correspondingnewvalueisnull.(Inthelattercase,theactualvalueinthecorresponding
values
entrydoesn’tmatter.)Notethat
nulls
isnotatextstring,justanarray:itdoesnotneeda
’\0’
terminator.
Return Value
newrowwithmodifications,allocatedintheupperexecutorcontext;
NULL
onlyif
row
is
NULL
1180
C# TIFF: How to Insert & Burn Picture/Image into TIFF Document
Support adding image or picture to an existing or new new REImage(@"c:\ logo.png"); // add the image powerful & profession imaging controls, PDF document, tiff
add image to pdf java; adding images to pdf forms
VB.NET Image: Image Resizer Control SDK to Resize Picture & Photo
NET Method to Resize Image & Picture. Here we this VB.NET image resizer control add-on, can provide powerful & profession imaging controls, PDF document, image
how to add picture to pdf; add png to pdf preview
SPI_modifytuple
Onerror,
SPI_result
issetasfollows:
SPI_ERROR_ARGUMENT
if
rel
is
NULL
,orif
row
is
NULL
,orif
ncols
islessthanorequalto0,orif
colnum
is
NULL
,or
if
values
is
NULL
.
SPI_ERROR_NOATTRIBUTE
if
colnum
containsaninvalidcolumnnumber(lessthanorequalto0orgreaterthanthenumber
ofcolumnin
row
)
1181
VB.NET Image: How to Save Image & Print Image Using VB.NET
of saving and printing multi-page document files, like PDF and Word, in assembly with VB.NET web image viewer add-on, you VB.NET Method to Save Image / Picture.
add photo to pdf; adding jpg to pdf
VB.NET PowerPoint: Add Image to PowerPoint Document Slide/Page
image, clip art or screenshot, the picture will be AddPage", "InsertPage" and "DeletePage" to add, insert or & profession imaging controls, PDF document, tiff
how to add photo to pdf in preview; how to add a jpeg to a pdf file
SPI_freetuple
Name
SPI_freetuple—freearowallocatedintheupperexecutorcontext
Synopsis
void SPI_freetuple(HeapTuple
row
)
Description
SPI_freetuple
freesarowpreviouslyallocatedintheupperexecutorcontext.
Thisfunctionisnolongerdifferentfromplain
heap_freetuple
.It’s keptjustforbackwardcom-
patibilityofexistingcode.
Arguments
HeapTuple
row
rowtofree
1182
C# Image: How to Add Antique & Vintage Effect to Image, Photo
function to add antique charm to picture & photo C#.NET antique effect creating control add-on is powerful & profession imaging controls, PDF document, tiff
add photo to pdf for; adding images to pdf files
VB.NET Image: VB.NET Codes to Add Antique Effect to Image with .
mature technology to replace a picture's original colors add the glow and noise, and add a little powerful & profession imaging controls, PDF document, image
add image to pdf file; how to add image to pdf in preview
SPI_freetuptable
Name
SPI_freetuptable—freearowsetcreatedby
SPI_execute
orasimilarfunction
Synopsis
void SPI_freetuptable(SPITupleTable
tuptable
)
Description
SPI_freetuptable
frees a rowsetcreatedbya priorSPIcommandexecutionfunction,suchas
SPI_execute
.Therefore,this functionis oftencalledwiththe global variable
SPI_tuptable
as
argument.
ThisfunctionisusefulifaSPIprocedureneedstoexecutemultiplecommandsanddoesnotwantto
keeptheresultsofearliercommandsarounduntilitends.Notethatanyunfreedrowsetswillbefreed
anywayat
SPI_finish
.Also,ifasubtransactionisstartedandthenabortedwithinexecutionofa
SPIprocedure,SPIautomaticallyfreesanyrowsetscreatedwhilethesubtransactionwasrunning.
BeginninginPostgreSQL9.3,
SPI_freetuptable
containsguardlogictoprotectagainstduplicate
deletionrequestsforthesamerowset.Inpreviousreleases,duplicatedeletionswouldleadtocrashes.
Arguments
SPITupleTable
tuptable
pointertorowsettofree,orNULLtodonothing
1183
SPI_freeplan
Name
SPI_freeplan—freeapreviouslysavedpreparedstatement
Synopsis
int SPI_freeplan(SPIPlanPtr
plan
)
Description
SPI_freeplan
releases a prepared statement previously returned by
SPI_prepare
or saved by
SPI_keepplan
or
SPI_saveplan
.
Arguments
SPIPlanPtr
plan
pointertostatementtofree
Return Value
0onsuccess;
SPI_ERROR_ARGUMENT
if
plan
is
NULL
orinvalid
1184
Chapter44.ServerProgrammingInterface
44.4. Visibility of Data Changes
Thefollowingrulesgovernthevisibilityofdata changes infunctionsthatuse SPI(oranyotherC
function):
DuringtheexecutionofanSQLcommand,anydatachangesmadebythecommandareinvisible
tothecommanditself.Forexample,in:
INSERT INTO a SELECT
*
FROM a;
theinsertedrowsareinvisibletothe
SELECT
part.
Changes made bya commandC are visible to all commands thatarestartedafterC,nomatter
whethertheyarestartedinsideC(duringtheexecutionofC)orafterCisdone.
Commands executed via SPI inside a function calledby anSQL command (either an ordinary
functionoratrigger)followoneortheotheroftheaboverulesdependingontheread/writeflag
passedtoSPI.Commandsexecutedinread-onlymodefollowthefirstrule:theycannotseechanges
ofthecallingcommand.Commandsexecutedinread-writemodefollowthesecondrule:theycan
seeallchangesmadesofar.
AllstandardprocedurallanguagessettheSPIread-writemodedependingonthevolatilityattribute
of the function.Commands of
STABLE
and
IMMUTABLE
functions are done inread-onlymode,
whilecommandsof
VOLATILE
functionsaredoneinread-writemode.WhileauthorsofCfunctions
areabletoviolatethisconvention,it’sunlikelytobeagoodideatodoso.
Thenextsectioncontainsanexamplethatillustratestheapplicationoftheserules.
44.5. Examples
ThissectioncontainsaverysimpleexampleofSPIusage.Theprocedure
execq
takesanSQLcom-
mandas itsfirstargumentandarowcountas its second,executes thecommandusing
SPI_exec
andreturnsthe numberofrows thatwereprocessedbythecommand.Youcanfindmore complex
examplesforSPIinthesourcetreein
src/test/regress/regress.c
andinthespimodule.
#include "postgres.h"
#include "executor/spi.h"
#include "utils/builtins.h"
#ifdef PG_MODULE_MAGIC
PG_MODULE_MAGIC;
#endif
int execq(text
*
sql, int cnt);
int
execq(text
*
sql, int cnt)
{
char
*
command;
int ret;
int proc;
/
*
Convert given text object to a C string
*
/
1185
Chapter44.ServerProgrammingInterface
command = text_to_cstring(sql);
SPI_connect();
ret = SPI_exec(command, cnt);
proc = SPI_processed;
/
*
*
If some rows were fetched, print them via elog(INFO).
*
/
if (ret > 0 && SPI_tuptable != NULL)
{
TupleDesc tupdesc = SPI_tuptable->tupdesc;
SPITupleTable
*
tuptable = SPI_tuptable;
char buf[8192];
int i, j;
for (j = 0; j < proc; j++)
{
HeapTuple tuple = tuptable->vals[j];
for (i = 1, buf[0] = 0; i <= tupdesc->natts; i++)
snprintf(buf + strlen (buf), sizeof(buf) - strlen(buf), " %s%s",
SPI_getvalue(tuple, tupdesc, i),
(i == tupdesc->natts) ? " " : " |");
elog(INFO, "EXECQ: %s", buf);
}
}
SPI_finish();
pfree(command);
return (proc);
}
(Thisfunctionusescallconventionversion0,tomaketheexampleeasiertounderstand.Inrealappli-
cationsyoushouldusethenewversion1interface.)
This is howyou declare the functionafterhavingcompiledit intoa sharedlibrary (details are in
Section35.9.6.):
CREATE FUNCTION execq(text, integer) RETURNS integer
AS ’
filename
LANGUAGE C;
Hereisasamplesession:
=> SELECT execq(’CREATE TABLE a (x integer)’, 0);
execq
-------
0
(1 row)
=> INSERT INTO a VALUES (execq(’INSERT INTO a VALUES (0)’, 0));
INSERT 0 1
=> SELECT execq(’SELECT
*
FROM a’, 0);
1186
Chapter44.ServerProgrammingInterface
INFO:
EXECQ:
0
-- inserted by execq
INFO:
EXECQ:
1
-- returned by execq and inserted by upper INSERT
execq
-------
2
(1 row)
=> SELECT execq(’INSERT INTO a SELECT x + 2 FROM a’, 1);
execq
-------
1
(1 row)
=> SELECT execq(’SELECT
*
FROM a’, 10);
INFO:
EXECQ:
0
INFO:
EXECQ:
1
INFO:
EXECQ:
2
-- 0 + 2, only one row inserted - as specified
execq
-------
3
-- 10 is the max value only, 3 is the real number of rows
(1 row)
=> DELETE FROM a;
DELETE 3
=> INSERT INTO a VALUES (execq(’SELECT
*
FROM a’, 0) + 1);
INSERT 0 1
=> SELECT
*
FROM a;
x
---
1
-- no rows in a (0) + 1
(1 row)
=> INSERT INTO a VALUES (execq(’SELECT
*
FROM a’, 0) + 1);
INFO:
EXECQ:
1
INSERT 0 1
=> SELECT
*
FROM a;
x
---
1
2
-- there was one row in a + 1
(2 rows)
-- This demonstrates the data changes visibility rule:
=> INSERT INTO a SELECT execq(’SELECT
*
FROM a’, 0)
*
x FROM a;
INFO:
EXECQ:
1
INFO:
EXECQ:
2
INFO:
EXECQ:
1
INFO:
EXECQ:
2
INFO:
EXECQ:
2
INSERT 0 2
=> SELECT
*
FROM a;
x
---
1
1187
Documents you may be interested
Documents you may be interested