Click here to monitor SSC
SQLServerCentral is supported by Red Gate Software Ltd.
 
Log in  ::  Register  ::  Not logged in
 
 
 
        
Home       Members    Calendar    Who's On


Add to briefcase «««1234

Replace Expand / Collapse
Author
Message
Posted Thursday, October 3, 2013 10:02 PM
Grasshopper

GrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopper

Group: General Forum Members
Last Login: Saturday, November 16, 2013 2:05 AM
Points: 17, Visits: 46
Can any one help to get quick results while running query in PostgreSQL?

when i run my query its taking such a long time due to huge data's in db.

Thanks,
Shobana
Post #1501408
Posted Friday, October 4, 2013 1:04 AM


SSCertifiable

SSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiable

Group: General Forum Members
Last Login: Today @ 8:09 AM
Points: 6,750, Visits: 13,896
shobanapraveen (10/3/2013)
Can any one help to get quick results while running query in PostgreSQL?

when i run my query its taking such a long time due to huge data's in db.

Thanks,
Shobana


Have you tried posting in a PostgreSQL forum? Most folks reading this will have no experience of the product.
Failing that, good query design practices for SQL Server are quite likely to apply to a PostgreSQL query. Post it up!


“Write the query the simplest way. If through testing it becomes clear that the performance is inadequate, consider alternative query forms.” - Gail Shaw

For fast, accurate and documented assistance in answering your questions, please read this article.
Understanding and using APPLY, (I) and (II) Paul White
Hidden RBAR: Triangular Joins / The "Numbers" or "Tally" Table: What it is and how it replaces a loop Jeff Moden
Exploring Recursive CTEs by Example Dwain Camps
Post #1501439
Posted Friday, October 4, 2013 2:21 AM
Forum Newbie

Forum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum Newbie

Group: General Forum Members
Last Login: Friday, October 4, 2013 2:07 AM
Points: 1, Visits: 2
try to search n propertly forum, i dont have information about it
Post #1501457
Posted Sunday, October 6, 2013 10:06 PM
Grasshopper

GrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopper

Group: General Forum Members
Last Login: Saturday, November 16, 2013 2:05 AM
Points: 17, Visits: 46
Hi,

Any online to help me in fetching the data's quickly. if i run the query below its taking such a long time due to huge data's(1k) in each tables. Can any one help me in this..............

Thanks,
Shobana


DROP TABLE IF EXISTS OwnerMessageList1;
DROP TABLE IF EXISTS OwnerMessageList2;

CREATE TEMPORARY TABLE OwnerMessageList1 (
id serial,
name varchar(100)
);

CREATE TEMPORARY TABLE OwnerMessageList2 (
id serial,
srcname varchar(100),
url varchar(1000),
username varchar(200)
);


INSERT INTO OwnerMessageList1
(name)
select unnest(string_to_array(replace(replace('$filter', 'itime >= ', ''),'itime <= ',''),'and'));

INSERT INTO OwnerMessageList2
(srcname,url,username)
select distinct am.src,am.url,am.user from "FGT60B3908669009-wlog-1380091698" am where cast(am.itime as integer) between (select cast(name as integer) from OwnerMessageList1 where id=1) and (select cast(name as integer) from OwnerMessageList1 where id=2) ;

select am.srcname,am.url,am.username,abstime(cp.itime) as itime ,abstime(cp.dtime) as dtime from "SYSLOG-C0A80A41-glog-1380349435" cp join OwnerMessageList2 am on cp.msg LIKE '%'||am.srcname||'%' where cast(cp.itime as integer) between (select cast(name as integer) from OwnerMessageList1 where id=1) and (select cast(name as integer) from OwnerMessageList1 where id=2) order by cp.itime desc
Post #1501983
Posted Tuesday, October 8, 2013 10:54 PM
Grasshopper

GrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopperGrasshopper

Group: General Forum Members
Last Login: Saturday, November 16, 2013 2:05 AM
Points: 17, Visits: 46
Hi,



Any one help me to insert datas into mysql.


Thanks,
Shobana
Post #1502912
Posted Wednesday, October 9, 2013 2:35 AM


SSC Eights!

SSC Eights!SSC Eights!SSC Eights!SSC Eights!SSC Eights!SSC Eights!SSC Eights!SSC Eights!

Group: General Forum Members
Last Login: Today @ 5:51 AM
Points: 916, Visits: 2,881
shobanapraveen (10/8/2013)
Hi,

Any one help me to insert datas into mysql.

Thanks,
Shobana

http://dev.mysql.com/doc/




The SQL Guy @ blogspot

@SeanPearceSQL

About Me
Post #1502963
« Prev Topic | Next Topic »

Add to briefcase «««1234

Permissions Expand / Collapse