On Wed, Jul 2, 2014 at 3:27 PM, Arup Rakshit
wrote:
> Here is my try :
>
> staging::=> select to_char(created_at,'DD/MM') || '/' ||
> to_char(now(),'') as when from users;
> when
>
> 24/02/2014
> 28/02/2014
> 02/03/2014
> 01/03/2014
> 04/03/2014
> 02/03/2014
> 06/03/2
Here is my try :
>
>
>staging::=> select to_char(created_at,'DD/MM') || '/' ||
>to_char(now(),'') as when from users;
> when
>
> 24/02/2014
> 28/02/2014
> 02/03/2014
> 01/03/2014
> 04/03/2014
> 02/03/2014
> 06/03/2014
> 07/05/2014
> 02/06/2014
> 06/06/2014
> 20/02/2014
>
On 30 June 2014 15:05, Bob Jolliffe wrote:
> What are people's thoughts about a more optimal solution? I would like to
> use a more incremental approach to replication. This does not have to be a
> "live" replication .. asynchronously triggering once every 24 hours is
> sufficient. Also there
On 07/02/2014 12:48 AM, Arup Rakshit wrote:
What is the data at your disposal when trying to select the current
year? If it is a timestamp, simply use date_part:
=# select date_part('year', now());
date_part
---
2014
(1 row)
--
Michael
It is *datetime*. Now my users are c
My highest priority has just changed to developing a multiuser database
application. The backend is postgres, of course, and everything else will be
written in Python, SQLAlchemy, and wxPython. This application is at least
one order of magnitude more complicated/sophisticated than any I have
de
On 07/02/2014 06:17 AM, Rich Shepard wrote:
-- Set user roles
CREATE ROLE admin LOGIN;
CREATE ROLE executive;
CREATE ROLE manager;
CREATE ROLE technician;
and my question is what do I need to do so when a user is added to the
system the local administrator and the group specified during the
cr
Rich Shepard writes:
> ... my question is what do I need to do so when a user is added to the
> system the local administrator and the group specified during the createuser
> process, she or he can be granted that group's privileges?
I might be misunderstanding, but I think you're looking for GRA
On Wed, 2 Jul 2014, Tom Lane wrote:
I might be misunderstanding, but I think you're looking for GRANT/REVOKE:
GRANT rolename TO newuser;
tom,
You correctly understand my question. That's the syntax I need and did not
see.
Thank you,
Rich
--
Sent via pgsql-general mailing list (pgsql-g
Tom Lane-2 wrote
> Rich Shepard <
> rshepard@
> > writes:
>> ... my question is what do I need to do so when a user is added to the
>> system the local administrator and the group specified during the
>> createuser
>> process, she or he can be granted that group's privileges?
>
> I might be misu
Adrian Klaver-4 wrote
> On 07/02/2014 12:48 AM, Arup Rakshit wrote:
>>
>
>>
>> What is the data at your disposal when trying to select the current
>> year? If it is a timestamp, simply use date_part:
>> =# select date_part('year', now());
>> date_part
>>
>> ---
>>2014
>>
>> (1 ro
On 07/02/2014 06:17 AM, Rich Shepard wrote:
Or, is that
automatic if the role is included in the Users table?
To follow up on my previous post. If you have your own user table,
having a user in that table with the same name as one of the Postgres
role does not mean they pick up the Postgres
On Wed, 2 Jul 2014, David G Johnston wrote:
or if you want to do it as part of creating a new user:
CREATE ROLE new_management_user
[other stuff here]
IN ROLE management;
http://www.postgresql.org/docs/9.2/interactive/sql-createrole.html
David,
I'll have to think deeply about what this is
On Wed, 2 Jul 2014, Adrian Klaver wrote:
To follow up on my previous post. If you have your own user table, having a
user in that table with the same name as one of the Postgres role does not
mean they pick up the Postgres role permissions.
Adrian,
OK. Now I see the issue.
What I have c
Rich Shepard wrote
> On Wed, 2 Jul 2014, David G Johnston wrote:
>
>> or if you want to do it as part of creating a new user:
>>
>> CREATE ROLE new_management_user
>> [other stuff here]
>> IN ROLE management;
>>
>> http://www.postgresql.org/docs/9.2/interactive/sql-createrole.html
>
> David,
>
>
On Wed, Jul 2, 2014 at 7:50 AM, Rich Shepard
wrote:
> On Wed, 2 Jul 2014, David G Johnston wrote:
>
> or if you want to do it as part of creating a new user:
>>
>> CREATE ROLE new_management_user
>> [other stuff here]
>> IN ROLE management;
>>
>> http://www.postgresql.org/docs/9.2/interactive/sq
On 07/01/2014 11:27 PM, Arup Rakshit wrote:
Here is my try :
staging::=> select to_char(created_at,'DD/MM') || '/' ||
to_char(now(),'') as when from users;
when
24/02/2014
...
20/02/2014
(15 rows)
Can the same be done using any other clever trick ?
No tricks are spr
I‘v changed cmd (in win8) to encoding utf8 through chcp 65001, but error
still occurs.
And i use the following cmd to dump mysql data:
mysql> select Picture from personpicture where id =
'F2931306D1EE44ca82394CD3BC2404D4' into outfile "d:\\1.txt" ;
I got the ansi file, and use Ultraedit to see fir
On 07/02/2014 07:50 AM, Rich Shepard wrote:
On Wed, 2 Jul 2014, David G Johnston wrote:
or if you want to do it as part of creating a new user:
CREATE ROLE new_management_user
[other stuff here]
IN ROLE management;
http://www.postgresql.org/docs/9.2/interactive/sql-createrole.html
David,
On Wednesday, July 02, 2014 08:42:43 AM Steve Crawford wrote:
> On 07/01/2014 11:27 PM, Arup Rakshit wrote:
> > Here is my try :
> >
> > staging::=> select to_char(created_at,'DD/MM') || '/' ||
> > to_char(now(),'') as when from users;
> >
> > when
> >
> >
> >
> > 24/02/2
On Wed, 2 Jul 2014, David G Johnston wrote:
Its the exact same outcome Tom provided, just via a different mechanism...
You want to assign all permissions to the standard group-roles and then
have new users inherit the appropriate permissions via their membership in
the appropriate group-role.
Hi,
I am working on web development project. There I am using this awesome DB. Let
me tell you first the schema that I am having associated the problem.
I am having a table *users* - which has many fields. Out of them, the one I
need here is *gender*. This column can have value "f"/"m"/"n".
I
On Wed, 2 Jul 2014, Gregory Haase wrote:
If it made you feel better, remember that CREATE USER is an alias for
CREATE ROLE that includes LOGIN by default.
Greg,
Yes, I read that in the docs.
So if you simply swap one word in your command, the context becomes a
little more clear for what y
you have:
GROUP BY users.gender, measures.option
instead try:
GROUP BY users
On Wed, Jul 2, 2014 at 12:55 PM, Arup Rakshit
wrote:
> Hi,
>
> I am working on web development project. There I am using this awesome DB.
> Let
> me tell you first the schema that I am having associated the problem.
>
On Wednesday, July 02, 2014 02:38:36 PM jared wrote:
> you have:
> GROUP BY users.gender, measures.option
>
> instead try:
> GROUP BY users
>
>
*group by* on full table(*users*). I am away from our production DB. Could you
tell me how this little change will solve the whole problem and help me
On Wed, Jul 2, 2014 at 1:44 PM, Arup Rakshit
wrote:
>
> *group by* on full table(*users*). I am away from our production DB. Could
> you
> tell me how this little change will solve the whole problem and help me to
> get
> the data as per the format I am looking for.
>
Arup,
I meant:
GROUP BY use
On 7/2/2014 10:44 AM, Arup Rakshit wrote:
*group by* on full table(*users*). I am away from our production DB. Could you
tell me how this little change will solve the whole problem and help me to get
the data as per the format I am looking for.
I believe he meant
group by users.gender
On Wednesday, July 02, 2014 02:49:54 PM you wrote:
> On Wed, Jul 2, 2014 at 1:44 PM, Arup Rakshit
>
> wrote:
> > *group by* on full table(*users*). I am away from our production DB. Could
> > you
> > tell me how this little change will solve the whole problem and help me to
> > get
> > the data a
On 07/02/2014 09:55 AM, Arup Rakshit wrote:
SELECT users.gender,count(*) as participant,avg(daily_action_answers.value) as
value
FROM "users" INNER JOIN "daily_action_answers" ON
"daily_action_answers"."user_id" = "users"."id"
INNER JOIN "measures" ON "measures"."id" = "daily_action_answers"."mea
Steve Crawford wrote
> On 07/02/2014 09:55 AM, Arup Rakshit wrote:
>> SELECT users.gender,count(*) as
>> participant,avg(daily_action_answers.value) as
>> value
>> FROM "users" INNER JOIN "daily_action_answers" ON
>> "daily_action_answers"."user_id" = "users"."id"
>> INNER JOIN "measures" ON "measu
On Wednesday, July 02, 2014 12:28:04 PM David G Johnston wrote:
> Steve Crawford wrote
>
>
> Are you sure this is what you want?
>
> Since there are two columns you will have to either use a CASE or a select
> to facilitate calculating the values for each of the columns.
>
> SELECT gender, ans
Toby Corkindale wrote:
> From: "Patrick Simcoe"
>> I have a question regarding two-way encryption data for specific columns.
>>
>> Does anyone have a technique or recommendation for two-way encryption which
>> somehow obfuscates the decrypt key so that it isn't easily retrievable from
>> the dat
> how would an instance of your program know what to connect to, or which
> previous instance its 'predecessor' was ?
> normally, you have ONE database for a given set of applications, and all
> the applications share the same database tables and such.
That's the problem, is there some way to t
Afternoon Frank,
I believe what you might wish to look at is a single database with a set of
schemas[1] which would separate your data in a logical way. You could have
a single connection url and then each individual connection could create a
schema (or reuse if you wish), set the search path (fir
> how would an instance of your program know what to connect to, or which
> previous instance its 'predecessor' was ?
> normally, you have ONE database for a given set of applications, and all
> the applications share the same database tables and such.
That's the problem, is there some way to t
On Wednesday, July 02, 2014 12:28:04 PM David G Johnston wrote:
> Steve Crawford wrote
>
>
> Are you sure this is what you want?
>
> Since there are two columns you will have to either use a CASE or a select
> to facilitate calculating the values for each of the columns.
>
> SELECT gender, ans
afonit wrote
>> genderparticipants answer1_avg answer2_avg
>> n 3 12 3
>> m 5 4 12
>> f 71523
Are you sure t
Hi
I've just noticed that the EDB-produced installer for Pg omits a number
of components required to build things that're fully compatible with
libpq if they also use some of the same libs as libpq, like libintl,
openssl, etc.
The specific case of interest to me is psqlODBC, which I've been doing
On 02 Jul 2014, at 18:55, Arup Rakshit wrote:
> Hi,
>
> I am working on web development project. There I am using this awesome DB.
> Let
> me tell you first the schema that I am having associated the problem.
>
> I am having a table *users* - which has many fields. Out of them, the one I
> n
38 matches
Mail list logo