[Info-ingres] Issues with COPY TABLE statement with negative DECIMAL Values

Adrian Williamson adrian.williamson at rationalcommerce.com
Wed Sep 25 07:11:07 UTC 2019


Hi Darren,

 

When I am moving things around systems I use the "copydb -c" command to give
me the 'ASCII' i.e. non Binary syntax for extracting data.

 

e.g. copydb -c -uowner mydatabase mytable

 

This gives me a copy.out and in which I cannibalise.

 

Apologies if you have already tried this, but the phrase "but the output is
in a Binary format" made me think other wise.

 

Good luck

 

Adrian

 

 

From: info-ingres-bounces at lists.planetingres.org
<info-ingres-bounces at lists.planetingres.org> On Behalf Of Darren Harvey
Sent: 25 September 2019 07:45
To: info-ingres at lists.planetingres.org
Subject: [Info-ingres] Issues with COPY TABLE statement with negative
DECIMAL Values

 

Hi

 

I am attempting to export data from an Ingres Database using the COPY TABLE
statement, but having problems with fields defined as 'decimal' with
negative values.  The screen shot below shows part of 2 records being
exported into a text output file.  The 1st record has a decimal value of
78.00000 and displays correctly. However the 2nd record has a negative
decimal value of -0.40000 and the output places an '8' in front of the
value, which I assume is to indicate the value has 8 individual characters
(-0.40000).  The format in the COPY TABLE statement for this field is
'VARCHAR(0)'

 



 

When we try to import this data into a non-Ingres database table it fails
because of the character '8' at the start of the data for that field.

 

I have tried outputting this field with a Data Type of 'Decimal(0)',
'Decimal(11,5)' and 'Float(0)' in the COPY TABLE statement, but the output
is in a Binary format which again is unusable for the Import process. 



 

I have tested the Import we are attempting to use with the field in the text
file just displaying as '-0.40000' instead of '8-0.40000', and the import
works fine.  

 

Does anyone know if there is a way to output 'negative' values without that
leading 'length' value?

 

Thanks in Advance

 

Darren



Darren Harvey 


Senior Developer 


M +61 400 398 188 
P +61 3 9922 5519
Skype for Business ID darren.harvey at fusion5.com.au
<mailto:darren.harvey at fusion5.com.au>  


 
<https://www.fusion5.com.au/infusion?utm_source=F5-Int.Sig&utm_medium=email&
utm_campaign=AskUs2018/> www.fusion5.com.au
<https://www.linkedin.com/company/fusion5> 


Fusion5 | Level 27, 570 Bourke Street, Melbourne, 3000, Australia


This email and any attachments are confidential and intended exclusively for
the person to whom the email is addressed. Please see our
<https://www.fusion5.com.au/privacy-policy/> Privacy Policy 














 

From: info-ingres-bounces at lists.planetingres.org
<mailto:info-ingres-bounces at lists.planetingres.org>
<info-ingres-bounces at lists.planetingres.org
<mailto:info-ingres-bounces at lists.planetingres.org> > On Behalf Of Darren
Harvey
Sent: Monday, 29 July 2019 9:29 AM
To: info-ingres at lists.planetingres.org
<mailto:info-ingres at lists.planetingres.org> 
Subject: [Info-ingres] Performance of Primary Key v Index

 

Hi All

 

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?  

 

Thanks

 

Darren

 



Darren Harvey 


Senior Developer 


M +61 400 398 188
P +61 3 9922 5519 
Skype for Business ID darren.harvey at fusion5.com.au
<mailto:darren.harvey at fusion5.com.au>  


 
<https://www.fusion5.com.au/infusion?utm_source=F5-Int.Sig&utm_medium=email&
utm_campaign=AskUs2018/> www.fusion5.com.au
<https://www.linkedin.com/company/fusion5> 


 
<https://www.fusion5.com.au/es/hcm?utm_source=F5-Int.Sig&utm_medium=email&ut
m_campaign=Interested_HCM_2018/>  


Fusion5 | Level 27, 570 Bourke Street, Melbourne, 3000, Australia


This email and any attachments are confidential and intended exclusively for
the person to whom the email is addressed. Please see our
<https://www.fusion5.com.au/privacy-policy/> Privacy Policy 

 

 

Message protected by MailGuard: e-mail anti-virus, anti-spam and content
filtering.
http://www.mailguard.com.au/mg


Report this message as spam
<https://console.mailguard.com.au/ras/1WcHAvL2mZ/520gRpp5p5ZnDtbdWwXx5S/0.4>

 

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.planetingres.org/pipermail/info-ingres/attachments/20190925/d2e83182/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: image003.png
Type: image/png
Size: 2713 bytes
Desc: not available
URL: <https://lists.planetingres.org/pipermail/info-ingres/attachments/20190925/d2e83182/attachment.png>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: image004.png
Type: image/png
Size: 2542 bytes
Desc: not available
URL: <https://lists.planetingres.org/pipermail/info-ingres/attachments/20190925/d2e83182/attachment-0001.png>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: image006.png
Type: image/png
Size: 900 bytes
Desc: not available
URL: <https://lists.planetingres.org/pipermail/info-ingres/attachments/20190925/d2e83182/attachment-0002.png>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: image007.jpg
Type: image/jpeg
Size: 43812 bytes
Desc: not available
URL: <https://lists.planetingres.org/pipermail/info-ingres/attachments/20190925/d2e83182/attachment.jpg>


More information about the Info-ingres mailing list