Application compile file using Embeded SQL in Postgres4.7.2 - Mailing list pgsql-interfaces

From Kevin Cowley
Subject Application compile file using Embeded SQL in Postgres4.7.2
Date
Msg-id A170CC6BD457D3118EF800508B2C304805C366D4@mailhost.alchemetrics.co.uk
Whole thread Raw
Responses Re: Application compile file using Embeded SQL in
Re: Application compile file using Embeded SQL in Postgres4.7.2
List pgsql-interfaces
<div class="Section1"><p class="MsoNormal"><font face="Arial" size="2"><span style="font-size:10.0pt;
font-family:Arial"> </span></font><p class="MsoNormal"><font face="Arial" size="2"><span style="font-size:10.0pt;
font-family:Arial">I'm trying to build an embedded SQL app in <span class="SpellE">Postgres</span> 4.7.2 and failing at
thefirst hurdle - <span class="SpellE">Postgres</span> <span class="GramE">itself</span> compiles, starts, executes
withno problems.</span></font><p class="MsoNormal"><font face="Arial" size="2"><span style="font-size:10.0pt; 
font-family:Arial"> </span></font><p class="MsoNormal"><font face="Arial" size="2"><span style="font-size:10.0pt;
font-family:Arial">We're using <span class="SpellE">gcc</span> 3.2.2 on SLES 8</span></font><p class="MsoNormal"><font
face="Arial"size="2"><span style="font-size:10.0pt; 
font-family:Arial"> </span></font><p class="MsoNormal"><font face="Arial" size="2"><span style="font-size:10.0pt;
font-family:Arial">The problem I'm getting is that <span class="SpellE">ecpg</span> doesn't appear to able to generate
<spanclass="SpellE">compilable</span> code <span class="GramE">for<span style="mso-spacerun:yes"> 
</span>something</span>as simple as</span></font><p class="MsoNormal"><font face="Arial" size="2"><span
style="font-size:10.0pt;
font-family:Arial"> </span></font><p class="MsoNormal"><font face="Arial" size="2"><span style="font-size:10.0pt;
font-family:Arial">EXEC SQL CONNECT <span class="GramE">TO :target</span> USER :user;</span></font><p
class="MsoNormal"><fontface="Arial" size="2"><span style="font-size:10.0pt; 
font-family:Arial"> </span></font><p class="MsoNormal"><font face="Arial" size="2"><span style="font-size:10.0pt;
font-family:Arial">/sandbox/<span class="SpellE">cowleyke/src/SQL_Benchmarks/tst_postgres.pgc</span>: In function
`Connect':</span></font><pclass="MsoNormal"><font face="Arial" size="2"><span style="font-size:10.0pt; 
font-family:Arial">/sandbox/cowleyke/src/SQL_Benchmarks/tst_postgres.pgc:378: warning: passing <span
class="SpellE">arg</span>2 of `<span class="SpellE">ECPGconnect</span>' makes integer from pointer without a
cast</span></font><pclass="MsoNormal"><font face="Arial" size="2"><span style="font-size:10.0pt; 
font-family:Arial">/sandbox/cowleyke/src/SQL_Benchmarks/tst_postgres.pgc:378: too few arguments to function `<span
class="SpellE">ECPGconnect</span>'</span></font><pclass="MsoNormal"><font face="Arial" size="2"><span
style="font-size:10.0pt;
font-family:Arial"> </span></font><p class="MsoNormal"><font face="Arial" size="2"><span style="font-size:10.0pt;
font-family:Arial">This is not the only place this type of error occurs. Elsewhere I have</span></font><p
class="MsoNormal"><fontface="Arial" size="2"><span style="font-size:10.0pt; 
font-family:Arial"> </span></font><p class="MsoNormal"><font face="Arial" size="2"><span style="font-size:10.0pt;
font-family:Arial">EXCE SQL <span class="GramE">IMMEDIATE :stmt</span>;</span></font><p class="MsoNormal"><font
face="Arial"size="2"><span style="font-size:10.0pt; 
font-family:Arial"> </span></font><p class="MsoNormal"><span class="GramE"><font face="Arial" size="2"><span
style="font-size:10.0pt;font-family:Arial">Whichgives</span></font></span><font face="Arial" size="2"><span
style="font-size:10.0pt;font-family:Arial"></span></font><pclass="MsoNormal"><font face="Arial" size="2"><span
style="font-size:10.0pt;
font-family:Arial"> </span></font><p class="MsoNormal"><font face="Arial" size="2"><span style="font-size:10.0pt;
font-family:Arial">/sandbox/<span class="SpellE">cowleyke/src/SQL_Benchmarks/tst_postgres.pgc</span>: In function
`<spanclass="SpellE">ExecuteQuery</span>':</span></font><p class="MsoNormal"><font face="Arial" size="2"><span
style="font-size:10.0pt;
font-family:Arial">/sandbox/cowleyke/src/SQL_Benchmarks/tst_postgres.pgc:447: warning: passing <span
class="SpellE">arg</span>2 of `<span class="SpellE">ECPGdo</span>' makes integer from pointer without a
cast</span></font><pclass="MsoNormal"><font face="Arial" size="2"><span style="font-size:10.0pt; 
font-family:Arial">/sandbox/cowleyke/src/SQL_Benchmarks/tst_postgres.pgc:447: warning: passing <span
class="SpellE">arg</span>3 of `<span class="SpellE">ECPGdo</span>' makes integer from pointer without a
cast</span></font><pclass="MsoNormal"><font face="Arial" size="2"><span style="font-size:10.0pt; 
font-family:Arial">/sandbox/cowleyke/src/SQL_Benchmarks/tst_postgres.pgc:447: warning: passing <span
class="SpellE">arg</span>4 of `<span class="SpellE">ECPGdo</span>' makes pointer from integer without a
cast</span></font><pclass="MsoNormal"><font face="Arial" size="2"><span style="font-size:10.0pt; 
font-family:Arial"> </span></font><p class="section1" style="margin:0cm;margin-bottom:.0001pt"><font face="Times New
Roman"size="3"><span lang="EN-GB" style="font-size:12.0pt;mso-ansi-language:EN-GB;mso-no-proof:yes">Kevin
Cowley</span></font><spanlang="EN-GB" style="mso-ansi-language:EN-GB;mso-no-proof:yes"></span><p class="section1"
style="margin:0cm;margin-bottom:.0001pt"><fontface="Times New Roman" size="3"><span lang="EN-GB"
style="font-size:12.0pt;mso-ansi-language:
EN-GB;mso-no-proof:yes">R&D</span></font><p class="section1" style="margin:0cm;margin-bottom:.0001pt"><font
face="TimesNew Roman" size="3"><span lang="EN-GB" style="font-size:12.0pt;mso-ansi-language: 
EN-GB;mso-no-proof:yes"> </span></font><p class="section1" style="margin:0cm;margin-bottom:.0001pt"><font face="Times
NewRoman" size="2"><span lang="EN-GB" style="font-size:10.0pt;mso-ansi-language: 
EN-GB;mso-no-proof:yes">Tel: 0118 902 9099 (direct line)</span></font><p class="section1"
style="margin:0cm;margin-bottom:.0001pt"><fontface="Times New Roman" size="2"><span lang="EN-GB"
style="font-size:10.0pt;mso-ansi-language:
EN-GB;mso-no-proof:yes">Email: </span></font><span class="MsoHyperlink"><u><font color="blue" size="2"><span
style="font-size:10.0pt;mso-no-proof:yes">kevin.cowley@alchemetrics.co.uk</span></font></u></span><fontsize="2"><span
lang="EN-GB"style="font-size:10.0pt;mso-ansi-language:EN-GB; 
mso-no-proof:yes"></span></font><p class="section1" style="margin:0cm;margin-bottom:.0001pt"><font face="Times New
Roman"size="2"><span lang="EN-GB" style="font-size:10.0pt;mso-ansi-language: 
EN-GB;mso-no-proof:yes">Web: </span></font><span class="MsoHyperlink"><u><font color="blue" size="2"><span
style="font-size:10.0pt;mso-no-proof:yes">http://www.alchemetrics.co.uk</span></font></u></span><fontsize="2"><span
lang="EN-GB"style="font-size:10.0pt;mso-ansi-language:EN-GB"></span></font><p class="MsoNormal"><font face="Times New
Roman"size="3"><span style="font-size: 
12.0pt"> </span></font></div><font size="3"><br /><br />
**************************************************************************************<br/> ALCHEMETRICS LIMITED
(ALCHEMETRICS)<br/> Mulberry Park, Fishponds Road, Wokingham, Berkshire, RG41 2GX<br /> Tel: +44 (0) 118 902 9000 Fax:
+44(0) 118 902 9001<br /> This e-mail is confidential and is intended for the use of the addressee only.<br /> If you
arenot the intended recipient, you are hereby notified that you must <br /> not use, copy, disclose, otherwise
disseminateor take any action based on <br /> this e-mail or any information herein.<br /> If you receive this
transmissionin error, please notify the sender<br /> immediately by reply e-mail or by using the contact details above
andthen<br /> delete this e-mail.<br /> Please note that e-mail may be susceptible to data corruption, interception <br
/>and unauthorised amendment. Alchemetrics does not accept any liability for <br /> any such corruption, interception,
amendmentor the consequences thereof.<br />
**************************************************************************************<br/></font> 

pgsql-interfaces by date:

Previous
From: Joe Conway
Date:
Subject: Re: Tantalizing reference to passing data from NEW variable
Next
From: Christoph Haller
Date:
Subject: Re: I hope I'm missing something...