Re: [PERFORM] Store/Retrieve time series data from PostgreSQL

2017-09-14 Thread vinny
On 2017-09-14 13:51, Subramaniam C wrote: Hi QUERY :- _select distinct on (health_timeseries.mobid) mobid, health_timeseries.health, health_timeseries.hour from health_timeseries where hour >=(1505211054000/(3600*1000))-1 and hour <= 1505211054000/(3600*1000) ORDER BY health_timeseries.mobid DE

Re: [PERFORM] query runs for more than 24 hours!

2017-08-25 Thread vinny
On 2017-08-22 16:23, Mariel Cherkassky wrote: SELECT a.inst_prod_id, product_id, nap_area2, nap_phone_num, nap_product_id,

Re: [PERFORM] How to grant only create schemas and create database objects permission to user.

2017-07-19 Thread vinny
On 2017-07-19 14:23, Dinesh Chandra 12108 wrote: Dear expert, I have to create a user which have permission to CREATE SCHEMAS AND CREATE DATABASE OBJECTS in database. I am using postgres 9.1. Could you please assist me? Access control is managed using the GRANT command: https://www.postgres

Re: [PERFORM] Query with no result set, really really slow adding ORBDER BY / LIMIT clause

2017-04-20 Thread vinny
On 2017-04-20 13:16, Marco Renzi wrote: Thanks Philip, yes i tried, but that is not solving, still slow. Take a look at the log. -- Limit (cost=3.46..106.87 rows=10 width=4) (

Re: [PERFORM] Understanding PostgreSQL query execution time

2017-04-10 Thread vinny
On 2017-04-07 16:56, Haider Ali wrote: Hello I want to understand execution time of a query in PostgreSQL then I want to relate it to the problem i am getting. According to my observation ( I can't explain why this happen ) whenever we query a table first time its execution will be high (sometim

Re: [PERFORM] Filter certain range of IP address.

2017-04-10 Thread vinny
On 2017-04-07 17:29, David G. Johnston wrote: On Fri, Apr 7, 2017 at 8:18 AM, Dinesh Chandra 12108 wrote: Dear Vinny, Thanks for your valuable replay. but I need a select query, which select only that record which starts from IP "172.23.110" only from below table. xxx 172.

Re: [PERFORM] Filter certain range of IP address.

2017-04-07 Thread vinny
On 2017-04-07 16:13, Dinesh Chandra 12108 wrote: Hi expert, May I know how to select a range of IP address. Example: I have number of different-2 IP's present in a table. I HAVE TO SELECT ONLY THAT IP ADDRESS WHICH DOES NOT START FROM PREFIX “172.23.110”. Thanks in advance REGARDS, DINESH C

Re: [PERFORM] How Can I check PostgreSQL backup is successfully or not ?

2017-02-27 Thread vinny
On 2017-02-27 14:29, John Gorman wrote: Even though it's not listed in any of the documentation or “pg_dump --help” you can check the return code of the process. A return code greater than 0 (zero) usually indicates a failure ./bin >pg_dump -U dummy_user dummy_database; echo $? 1 FROM: pgsql-

Re: [PERFORM] DO I miss something ?

2016-11-18 Thread vinny
On 2016-11-18 14:52, Metatrader EA wrote: Hi, Do I miss something? Shouldn't I have some rows from this query ? Why is it empty? SELECT relname, idx_tup_fetch + seq_tup_read as TotalReads from pg_stat_all_tables WHERE idx_tup_fetch + seq_tup_read != 0 order by TotalReads desc LIMIT 10; rel

Re: [PERFORM] Sql Query :: Any advice ?

2016-11-15 Thread vinny
lance :: "hist_account_balance_ix1" btree (trade_no) trades :: "trades_pkey" PRIMARY KEY, btree (trade_no) "trades_trade_date_index" btree (trade_date) //H Quoting vinny : On 2016-11-15 14:27, Henrik Ekenberg wrote: Hi, I have some data to join and I want to get s

Re: [PERFORM] Sql Query :: Any advice ?

2016-11-15 Thread vinny
On 2016-11-15 14:27, Henrik Ekenberg wrote: Hi, I have some data to join and I want to get som advice from you. Any tips ? Any comments are apreciated //H select trade_no from forecast_trades.hist_account_balance left join trades using (trade_no) where trade_date > current_date - 120 and