473,320 Members | 1,868 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,320 software developers and data experts.

Export of data

Hello people!

I am a bit puzzled here so any help will be much appreciated.
Here is the situation:
I have a query which selects all the data based on a date column. I
need all the data which are
older than 130 days:

select count(*) from mytable where insert_date <= sysdate - 130

Currently the above query gives me a number of 31614 rows

The above data will be candidate for deletion. Before I delete I would
like to export this data.
Here is my parameter file:

userid=myuser/myuser@mydb
file=myfile.dmp
buffer=100000
log=myfile.log
tables=(
mytable
)
GRANTS=y
INDEXES=y
ROWS=y
CONSTRAINTS=n
QUERY='where insert_date<=sysdate - 130'

The export shows me that only 598 rows are exported? Shouldn't I get
31614 rows? Am i missing something here?

Thanks

Jul 19 '05 #1
3 3178
Hi,
I use this parameter but not with single quote here is my example:

QUERY=" where trunc(mvvalor) in (to_date('06.01.2005',
'dd.mm.yyyy'),to_date('11.01.2005', 'dd.mm.yyyy'),to_date('13.01.2005',
'dd.mm.yyyy'),to_date('18.01.2005', 'dd.mm.yyyy'))"

this export works here ...

Jul 19 '05 #2
Hi and thanks for the reply,

I have changed the single quotes to double quotes but still have the
same problem.

any other ideas?
Bobiander wrote:
Hi,
I use this parameter but not with single quote here is my example:

QUERY=" where trunc(mvvalor) in (to_date('06.01.2005',
'dd.mm.yyyy'),to_date('11.01.2005', 'dd.mm.yyyy'),to_date('13.01.2005', 'dd.mm.yyyy'),to_date('18.01.2005', 'dd.mm.yyyy'))"

this export works here ...


Jul 19 '05 #3
What is format of insert_date column , may be you must
trunc(insert_date) in where clause , also in my example I have a space
before WHERE , I remembrer that I try few times , before find what I am
looking for ..

trunc(insert_date) >= trunc(sysdate)

....

Boyan Boev

Jul 19 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

3
by: Bennett Haselton | last post by:
I'm working on an ASP.Net project where I want to test code on a local machine using a local database as a back-end, and then export it to the production machine where it uses the hosting...
0
by: Shawn Mehaffie | last post by:
I have the following class that I've wirtten to take a Dataset and automatically export it to either XML, ASCII or Tab delimited file. The reason I wrote it they way I did was that I don't want to...
1
by: Matt | last post by:
I have an ASP page that calls ASP routines that I created that execute a database query and return the results to a recordset. I then iterate through the recordset and display the data in a table....
1
by: Do Park via SQLMonster.com | last post by:
Hello all, I don?t often export data from a table. I am wondering how you export data from a table. I?d like to know how you export in real world. Do you export data from a table to a flat...
6
by: maricel | last post by:
Is there anybody out there who have any idea why EXPORT is relatively slower when putting the output file on a network drive - map drive from onother PC compared to putting it on my local PC drive...
1
by: Janne Ruuttunen | last post by:
Hello DB2 people, I'm having problems exporting >= 250000 lobs to IXF files with the LOBSINFILE option, using a legacy DB2 2.1 system on Win NT. If I don't specify a path for the lobs,...
0
by: Shawn Mehaffie | last post by:
I have the following class that I've wirtten to take a Dataset and automatically export it to either XML, ASCII or Tab delimited file. The reason I wrote it they way I did was that I don't want to...
1
by: chaitu | last post by:
Hi, Can anybody tell me what the error code for Export is. Like i get the message SQL3104N The Export utility is beginning to export data to file...
1
by: smaczylo | last post by:
Hello, I've recently been asked to work with Microsoft Access, and while I feel quite comfortable with Excel, I'm at a complete loss with databases. If someone could help me with this issue I'm...
0
by: kkshansid | last post by:
i cannot export my sql server database to msaccess database which i usually did successfully 3weeks ago pls help me to find the error so that i can correct it in future error is - Validating...
0
by: DolphinDB | last post by:
The formulas of 101 quantitative trading alphas used by WorldQuant were presented in the paper 101 Formulaic Alphas. However, some formulas are complex, leading to challenges in calculation. Take...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
by: ryjfgjl | last post by:
ExcelToDatabase: batch import excel into database automatically...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: PapaRatzi | last post by:
Hello, I am teaching myself MS Access forms design and Visual Basic. I've created a table to capture a list of Top 30 singles and forms to capture new entries. The final step is a form (unbound)...
0
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.