<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=us-ascii">
<meta name="Generator" content="Microsoft Word 14 (filtered medium)">
<!--[if !mso]><style>v\:* {behavior:url(#default#VML);}
o\:* {behavior:url(#default#VML);}
w\:* {behavior:url(#default#VML);}
.shape {behavior:url(#default#VML);}
</style><![endif]--><style><!--
/* Font Definitions */
@font-face
        {font-family:"MS Mincho";
        panose-1:2 2 6 9 4 2 5 8 3 4;}
@font-face
        {font-family:"MS Mincho";
        panose-1:2 2 6 9 4 2 5 8 3 4;}
@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
        {font-family:Tahoma;
        panose-1:2 11 6 4 3 5 4 4 2 4;}
@font-face
        {font-family:"\@MS Mincho";
        panose-1:2 2 6 9 4 2 5 8 3 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0cm;
        margin-bottom:.0001pt;
        font-size:11.0pt;
        font-family:"Calibri","sans-serif";
        mso-fareast-language:EN-US;}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:#0563C1;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {mso-style-priority:99;
        color:#954F72;
        text-decoration:underline;}
p
        {mso-style-priority:99;
        mso-margin-top-alt:auto;
        margin-right:0cm;
        mso-margin-bottom-alt:auto;
        margin-left:0cm;
        font-size:12.0pt;
        font-family:"Times New Roman","serif";}
p.msonormal0, li.msonormal0, div.msonormal0
        {mso-style-name:msonormal;
        mso-margin-top-alt:auto;
        margin-right:0cm;
        mso-margin-bottom-alt:auto;
        margin-left:0cm;
        font-size:11.0pt;
        font-family:"Calibri","sans-serif";}
span.EmailStyle18
        {mso-style-type:personal;
        font-family:"Calibri","sans-serif";
        color:windowtext;}
span.EmailStyle19
        {mso-style-type:personal;
        font-family:"Calibri","sans-serif";
        color:windowtext;}
span.EmailStyle20
        {mso-style-type:personal;
        font-family:"Calibri","sans-serif";
        color:windowtext;}
span.EmailStyle22
        {mso-style-type:personal-reply;
        font-family:"Calibri","sans-serif";
        color:#1F497D;}
.MsoChpDefault
        {mso-style-type:export-only;
        font-size:10.0pt;}
@page WordSection1
        {size:612.0pt 792.0pt;
        margin:72.0pt 72.0pt 72.0pt 72.0pt;}
div.WordSection1
        {page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1028" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]-->
</head>
<body lang="EN-GB" link="#0563C1" vlink="#954F72">
<div class="WordSection1">
<p class="MsoNormal"><span style="color:#1F497D">Hi Darren,<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D"><o:p>&nbsp;</o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">The varchar(0) format prefixes the length to the data. It did that on all lines so your 78.00000 is actually 8.00000 it&#8217;s 7 characters long.<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D"><o:p>&nbsp;</o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">Change the varchar(0) to a c0 and you should be OK.<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D"><o:p>&nbsp;</o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D">Martin Bowes<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D"><o:p>&nbsp;</o:p></span></p>
<div>
<div style="border:none;border-top:solid #B5C4DF 1.0pt;padding:3.0pt 0cm 0cm 0cm">
<p class="MsoNormal"><b><span lang="EN-US" style="font-size:10.0pt;font-family:&quot;Tahoma&quot;,&quot;sans-serif&quot;;mso-fareast-language:JA">From:</span></b><span lang="EN-US" style="font-size:10.0pt;font-family:&quot;Tahoma&quot;,&quot;sans-serif&quot;;mso-fareast-language:JA"> Darren Harvey
 [mailto:Darren.Harvey@fusion5.com.au] <br>
<b>Sent:</b> 25 September 2019 07:45<br>
<b>To:</b> info-ingres@lists.planetingres.org<br>
<b>Subject:</b> [Info-ingres] Issues with COPY TABLE statement with negative DECIMAL Values<o:p></o:p></span></p>
</div>
</div>
<p class="MsoNormal"><o:p>&nbsp;</o:p></p>
<p class="MsoNormal"><span lang="EN-AU">Hi<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-AU"><o:p>&nbsp;</o:p></span></p>
<p class="MsoNormal"><span lang="EN-AU">I am attempting to export data from an Ingres Database using the COPY TABLE statement, but having problems with fields defined as &#8216;decimal&#8217; with negative values.&nbsp; The screen shot below shows part of 2 records being exported
 into a text output file.&nbsp; The 1<sup>st</sup> record has a decimal value of 78.00000 and displays correctly. However the 2<sup>nd</sup> record has a negative decimal value of -0.40000 and the output places an &#8216;8&#8217; in front of the value, which I assume is to
 indicate the value has 8 individual characters (-0.40000).&nbsp; The format in the COPY TABLE statement for this field is &#8216;VARCHAR(0)&#8217;<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-AU"><o:p>&nbsp;</o:p></span></p>
<p class="MsoNormal"><span lang="EN-AU"><img width="401" height="35" id="Picture_x0020_1" src="cid:image003.png@01D57376.C7A0B170"><o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-AU"><o:p>&nbsp;</o:p></span></p>
<p class="MsoNormal"><span lang="EN-AU">When we try to import this data into a non-Ingres database table it fails because of the character &#8216;8&#8217; at the start of the data for that field.<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-AU"><o:p>&nbsp;</o:p></span></p>
<p class="MsoNormal"><span lang="EN-AU">I have tried outputting this field with a Data Type of &#8216;Decimal(0)&#8217;, &#8216;Decimal(11,5)&#8217; and &#8216;Float(0)&#8217; in the COPY TABLE statement, but the output is in a Binary format which again is unusable for the Import process.
<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-AU"><img width="269" height="39" id="Picture_x0020_4" src="cid:image004.png@01D57376.C7A0B170"><o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-AU"><o:p>&nbsp;</o:p></span></p>
<p class="MsoNormal"><span lang="EN-AU">I have tested the Import we are attempting to use with the field in the text file just displaying as &#8216;-0.40000&#8217; instead of &#8216;8-0.40000&#8217;, and the import works fine.&nbsp;
<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-AU"><o:p>&nbsp;</o:p></span></p>
<p class="MsoNormal"><span lang="EN-AU">Does anyone know if there is a way to output &#8216;negative&#8217; values without that leading &#8216;length&#8217; value?<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-AU"><o:p>&nbsp;</o:p></span></p>
<p class="MsoNormal"><span lang="EN-AU">Thanks in Advance<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-AU"><o:p>&nbsp;</o:p></span></p>
<p class="MsoNormal"><span lang="EN-AU">Darren<o:p></o:p></span></p>
<div>
<table class="MsoNormalTable" border="0" cellspacing="0" cellpadding="0" width="100%" style="width:100.0%;background:white;border-collapse:collapse">
<tbody>
<tr>
<td style="padding:12.0pt 12.0pt 24.0pt 12.0pt">
<table class="MsoNormalTable" border="0" cellspacing="0" cellpadding="0" align="left" width="400" style="width:300.0pt;background:white;border-collapse:collapse;margin-left:-2.25pt;margin-right:-2.25pt">
<tbody>
<tr>
<td width="600" style="width:450.0pt;border:none;border-top:solid #FD7B23 1.0pt;padding:7.5pt 0cm 0cm 0cm">
<p class="MsoNormal"><b><span style="font-size:15.0pt;color:#3A444A;mso-fareast-language:EN-AU">Darren Harvey
<o:p></o:p></span></b></p>
</td>
</tr>
<tr>
<td width="600" style="width:450.0pt;padding:0cm 0cm 0cm 0cm">
<p class="MsoNormal"><b><span style="font-size:10.5pt;color:#3A444A;mso-fareast-language:EN-AU">Senior Developer
<o:p></o:p></span></b></p>
</td>
</tr>
<tr>
<td width="600" style="width:450.0pt;padding:7.5pt 0cm 3.75pt 0cm">
<p class="MsoNormal"><b><span style="font-size:10.5pt;color:#3A444A;mso-fareast-language:EN-AU">M
</span></b><span style="font-size:10.5pt;color:#3A444A;mso-fareast-language:EN-AU">&#43;61 400 398 188
<br>
<b>P</b> &#43;61 3 9922 5519<br>
<b>Skype for Business ID</b> darren.harvey@fusion5.com.au <o:p></o:p></span></p>
</td>
</tr>
<tr>
<td width="600" style="width:450.0pt;border:none;border-bottom:solid #FD7B23 1.0pt;padding:3.75pt 0cm 3.75pt 0cm">
<p class="MsoNormal"><span style="font-size:10.5pt;color:#3A444A;mso-fareast-language:EN-AU"><a href="https://www.fusion5.com.au/infusion?utm_source=F5-Int.Sig&amp;utm_medium=email&amp;utm_campaign=AskUs2018/" target="_blank"><span style="color:#3A444A">www.fusion5.com.au</span></a>
</span><!--[if gte vml 1]><v:shapetype id="_x0000_t75" coordsize="21600,21600" o:spt="75" o:preferrelative="t" path="m@4@5l@4@11@9@11@9@5xe" filled="f" stroked="f">
<v:stroke joinstyle="miter" />
<v:formulas>
<v:f eqn="if lineDrawn pixelLineWidth 0" />
<v:f eqn="sum @0 1 0" />
<v:f eqn="sum 0 0 @1" />
<v:f eqn="prod @2 1 2" />
<v:f eqn="prod @3 21600 pixelWidth" />
<v:f eqn="prod @3 21600 pixelHeight" />
<v:f eqn="sum @0 0 1" />
<v:f eqn="prod @6 1 2" />
<v:f eqn="prod @7 21600 pixelWidth" />
<v:f eqn="sum @8 21600 0" />
<v:f eqn="prod @7 21600 pixelHeight" />
<v:f eqn="sum @10 21600 0" />
</v:formulas>
<v:path o:extrusionok="f" gradientshapeok="t" o:connecttype="rect" />
<o:lock v:ext="edit" aspectratio="t" />
</v:shapetype><v:shape id="Picture_x0020_3" o:spid="_x0000_s1027" type="#_x0000_t75" alt="Follow us on LinkedIn" href="https://www.linkedin.com/company/fusion5" target="&quot;_blank&quot;" style='position:absolute;margin-left:20.6pt;margin-top:0;width:61.5pt;height:16.5pt;z-index:251661312;visibility:visible;mso-wrap-style:square;mso-width-percent:0;mso-height-percent:0;mso-wrap-distance-left:0;mso-wrap-distance-top:0;mso-wrap-distance-right:0;mso-wrap-distance-bottom:0;mso-position-horizontal:right;mso-position-horizontal-relative:text;mso-position-vertical:absolute;mso-position-vertical-relative:line;mso-width-percent:0;mso-height-percent:0;mso-width-relative:page;mso-height-relative:page' o:allowoverlap="f" o:button="t">
<v:imagedata src="cid:image006.png@01D57376.C7A0B170" o:title="eDM-Logo_B3.v1-h22w82-LinkedInFollow" />
<w:wrap type="square"/>
</v:shape><![endif]--><![if !vml]><a href="https://www.linkedin.com/company/fusion5" target="&quot;_blank&quot;"><img border="0" width="82" height="22" src="cid:image006.png@01D57376.C7A0B170" align="right" alt="Follow us on LinkedIn" v:shapes="Picture_x0020_3"></a><![endif]><span style="font-size:10.5pt;color:#3A444A;mso-fareast-language:EN-AU"><o:p></o:p></span></p>
</td>
</tr>
<tr>
<td width="600" style="width:450.0pt;padding:7.5pt 0cm 0cm 0cm">
<p class="MsoNormal"><b><span style="font-size:10.5pt;color:#3A444A;mso-fareast-language:EN-AU">Fusion5 |</span></b><span style="font-size:10.5pt;color:#3A444A;mso-fareast-language:EN-AU"> Level 27, 570 Bourke Street, Melbourne, 3000, Australia<o:p></o:p></span></p>
</td>
</tr>
<tr>
<td width="600" style="width:450.0pt;padding:3.75pt 0cm 0cm 0cm">
<p class="MsoNormal"><span style="font-size:9.0pt;color:#3A444A;mso-fareast-language:EN-AU">This email and any attachments are confidential and intended exclusively for the person to whom the email is addressed. Please see our
<a href="https://www.fusion5.com.au/privacy-policy/" target="_blank"><span style="color:#3A444A">Privacy Policy</span></a>
<o:p></o:p></span></p>
</td>
</tr>
</tbody>
</table>
<p class="MsoNormal" style="margin-bottom:12.0pt"><span style="font-size:10.5pt;color:black;mso-fareast-language:EN-AU"><br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
</span><span style="font-size:10.5pt;mso-fareast-language:EN-AU"><o:p></o:p></span></p>
</td>
</tr>
</tbody>
</table>
</div>
<p class="MsoNormal"><span lang="EN-AU"><o:p>&nbsp;</o:p></span></p>
<div>
<div style="border:none;border-top:solid #E1E1E1 1.0pt;padding:3.0pt 0cm 0cm 0cm">
<p class="MsoNormal"><b><span lang="EN-US" style="mso-fareast-language:EN-AU">From:</span></b><span lang="EN-US" style="mso-fareast-language:EN-AU"> info-ingres-bounces@lists.planetingres.org &lt;info-ingres-bounces@lists.planetingres.org&gt;
<b>On Behalf Of </b>Darren Harvey<br>
<b>Sent:</b> Monday, 29 July 2019 9:29 AM<br>
<b>To:</b> info-ingres@lists.planetingres.org<br>
<b>Subject:</b> [Info-ingres] Performance of Primary Key v Index<o:p></o:p></span></p>
</div>
</div>
<p class="MsoNormal"><span lang="EN-AU"><o:p>&nbsp;</o:p></span></p>
<p class="MsoNormal"><span lang="EN-AU">Hi All<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-AU"><o:p>&nbsp;</o:p></span></p>
<p class="MsoNormal"><span lang="EN-AU">If I have a table that has a Primary Key with 2 columns in the key, does the Primary Key provide the same performance for selecting data on those 2 columns as an Index would with the same 2 columns? &nbsp;<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-AU"><o:p>&nbsp;</o:p></span></p>
<p class="MsoNormal"><span lang="EN-AU">Thanks<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-AU"><o:p>&nbsp;</o:p></span></p>
<p class="MsoNormal"><span lang="EN-AU">Darren<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-AU"><o:p>&nbsp;</o:p></span></p>
<table class="MsoNormalTable" border="0" cellspacing="0" cellpadding="0" width="100%" style="width:100.0%;background:white;border-collapse:collapse">
<tbody>
<tr>
<td style="padding:12.0pt 12.0pt 24.0pt 12.0pt">
<table class="MsoNormalTable" border="0" cellspacing="0" cellpadding="0" align="left" width="400" style="width:300.0pt;background:white;border-collapse:collapse;margin-left:-2.25pt;margin-right:-2.25pt">
<tbody>
<tr>
<td width="600" style="width:450.0pt;border:none;border-top:solid #FD7B23 1.0pt;padding:7.5pt 0cm 0cm 0cm">
<p class="MsoNormal"><b><span style="font-size:15.0pt;color:#3A444A;mso-fareast-language:EN-AU">Darren Harvey
<o:p></o:p></span></b></p>
</td>
</tr>
<tr>
<td width="600" style="width:450.0pt;padding:0cm 0cm 0cm 0cm">
<p class="MsoNormal"><b><span style="font-size:10.5pt;color:#3A444A;mso-fareast-language:EN-AU">Senior Developer
<o:p></o:p></span></b></p>
</td>
</tr>
<tr>
<td width="600" style="width:450.0pt;padding:7.5pt 0cm 3.75pt 0cm">
<p class="MsoNormal"><b><span style="font-size:10.5pt;color:#3A444A;mso-fareast-language:EN-AU">M</span></b><span style="font-size:10.5pt;color:#3A444A;mso-fareast-language:EN-AU"> &#43;61 400 398 188<br>
<b>P </b>&#43;61 3 9922 5519 <br>
<b>Skype for Business ID</b> <a href="mailto:darren.harvey@fusion5.com.au">darren.harvey@fusion5.com.au</a>
<o:p></o:p></span></p>
</td>
</tr>
<tr>
<td width="600" style="width:450.0pt;border:none;border-bottom:solid #FD7B23 1.0pt;padding:3.75pt 0cm 3.75pt 0cm">
<p class="MsoNormal"><span style="font-size:10.5pt;color:#3A444A;mso-fareast-language:EN-AU"><a href="https://www.fusion5.com.au/infusion?utm_source=F5-Int.Sig&amp;utm_medium=email&amp;utm_campaign=AskUs2018/" target="_blank"><span style="color:#3A444A">www.fusion5.com.au</span></a>
</span><!--[if gte vml 1]><v:shape id="Picture_x0020_2" o:spid="_x0000_s1026" type="#_x0000_t75" alt="Follow us on LinkedIn" href="https://www.linkedin.com/company/fusion5" target="&quot;_blank&quot;" style='position:absolute;margin-left:30.9pt;margin-top:0;width:61.5pt;height:16.5pt;z-index:251659264;visibility:visible;mso-wrap-style:square;mso-width-percent:0;mso-height-percent:0;mso-wrap-distance-left:0;mso-wrap-distance-top:0;mso-wrap-distance-right:0;mso-wrap-distance-bottom:0;mso-position-horizontal:right;mso-position-horizontal-relative:text;mso-position-vertical:absolute;mso-position-vertical-relative:line;mso-width-percent:0;mso-height-percent:0;mso-width-relative:page;mso-height-relative:page' o:allowoverlap="f" o:button="t">
<v:imagedata src="cid:image006.png@01D57376.C7A0B170" o:title="eDM-Logo_B3" />
<w:wrap type="square"/>
</v:shape><![endif]--><![if !vml]><a href="https://www.linkedin.com/company/fusion5" target="&quot;_blank&quot;"><img border="0" width="82" height="22" src="cid:image006.png@01D57376.C7A0B170" align="right" alt="Follow us on LinkedIn" v:shapes="Picture_x0020_2"></a><![endif]><span style="font-size:10.5pt;color:#3A444A;mso-fareast-language:EN-AU"><o:p></o:p></span></p>
</td>
</tr>
<tr>
<td width="600" style="width:450.0pt;padding:7.5pt 0cm 7.5pt 0cm">
<p class="MsoNormal"><span style="font-size:10.5pt;color:#3A444A;mso-fareast-language:EN-AU">&nbsp;</span><span style="color:black"><a href="https://www.fusion5.com.au/es/hcm?utm_source=F5-Int.Sig&amp;utm_medium=email&amp;utm_campaign=Interested_HCM_2018/"><span style="font-size:10.5pt;color:#3A444A;mso-fareast-language:EN-AU;text-decoration:none"><img border="0" width="400" height="150" id="_x0000_i1025" src="cid:image007.jpg@01D57376.C7A0B170"></span></a></span><span style="font-size:10.5pt;color:#3A444A;mso-fareast-language:EN-AU">
<o:p></o:p></span></p>
</td>
</tr>
<tr>
<td width="600" style="width:450.0pt;padding:7.5pt 0cm 0cm 0cm">
<p class="MsoNormal"><b><span style="font-size:10.5pt;color:#3A444A;mso-fareast-language:EN-AU">Fusion5 |</span></b><span style="font-size:10.5pt;color:#3A444A;mso-fareast-language:EN-AU"> Level 27, 570 Bourke Street, Melbourne, 3000, Australia<o:p></o:p></span></p>
</td>
</tr>
<tr>
<td width="600" style="width:450.0pt;padding:3.75pt 0cm 0cm 0cm">
<p class="MsoNormal"><span style="font-size:9.0pt;color:#3A444A;mso-fareast-language:EN-AU">This email and any attachments are confidential and intended exclusively for the person to whom the email is addressed. Please see our
<a href="https://www.fusion5.com.au/privacy-policy/" target="_blank"><span style="color:#3A444A">Privacy Policy</span></a>
<o:p></o:p></span></p>
</td>
</tr>
</tbody>
</table>
</td>
</tr>
</tbody>
</table>
<p class="MsoNormal"><span lang="EN-AU"><o:p>&nbsp;</o:p></span></p>
<p class="MsoNormal"><span lang="EN-AU" style="mso-fareast-language:EN-AU"><o:p>&nbsp;</o:p></span></p>
<p><span lang="EN-AU">Message protected by MailGuard: e-mail anti-virus, anti-spam and content filtering.<br>
<a href="http://www.mailguard.com.au/mg">http://www.mailguard.com.au/mg</a><o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-AU" style="mso-fareast-language:EN-AU"><br>
<a href="https://console.mailguard.com.au/ras/1WcHAvL2mZ/520gRpp5p5ZnDtbdWwXx5S/0.4">Report this message as spam</a> &nbsp;<br>
&nbsp;<o:p></o:p></span></p>
</div>
</body>
</html>