Thread: psql and \p\g
I have found that typing: test=> select * from pg_class\p\g no longer works. I honors the \p, but ignores the \g. Any ideas Peter? -- Bruce Momjian | http://www.op.net/~candle maillist@candle.pha.pa.us | (610) 853-3000+ If your life is a hard drive, | 830 Blythe Avenue + Christ can be your backup. | Drexel Hill, Pennsylvania19026
On 1999-11-11, Bruce Momjian mentioned: > I have found that typing: > > test=> select * from pg_class\p\g > > no longer works. I honors the \p, but ignores the \g. > > Any ideas Peter? select * from foo \p \g This was done to normalize the grammar a little bit (haha, very funny). In particular it allows this sort of stuff: => select * from foo \p \o out.txt \g \\ select * from foo 2 \x \g etc. Is it *really* necessary to be able to omit the space? -- Peter Eisentraut Sernanders vaeg 10:115 peter_e@gmx.net 75262 Uppsala http://yi.org/peter-e/ Sweden
> On 1999-11-11, Bruce Momjian mentioned: > > > I have found that typing: > > > > test=> select * from pg_class\p\g > > > > no longer works. I honors the \p, but ignores the \g. > > > > Any ideas Peter? > > select * from foo \p \g > > This was done to normalize the grammar a little bit (haha, very > funny). In particular it allows this sort of stuff: > => select * from foo \p \o out.txt \g \\ select * from foo 2 \x \g > etc. > > Is it *really* necessary to be able to omit the space? > Yes, I believe it is, in the sense that many people are used to doing them together. Can a backslash trigger some separation of commands, or at least \p\g be recognized correctly. I don't think there are other meaningful combinations. Can you add a unix-style timestamp for \T? -- Bruce Momjian | http://www.op.net/~candle maillist@candle.pha.pa.us | (610) 853-3000+ If your life is a hard drive, | 830 Blythe Avenue + Christ can be your backup. | Drexel Hill, Pennsylvania19026
Bruce Momjian <maillist@candle.pha.pa.us> writes: >> This was done to normalize the grammar a little bit (haha, very >> funny). In particular it allows this sort of stuff: >> => select * from foo \p \o out.txt \g \\ select * from foo 2 \x \g >> etc. >> >> Is it *really* necessary to be able to omit the space? > Yes, I believe it is, in the sense that many people are used to doing > them together. Can a backslash trigger some separation of commands, or > at least \p\g be recognized correctly. I don't think there are other > meaningful combinations. It'd probably be sufficient if backslash-commands that never take parameters can be adjacent to a following backslash command. regards, tom lane
On Thu, 11 Nov 1999, Bruce Momjian wrote: > Can you add a unix-style timestamp for \T? Do you mean \echo `date` ? -- Peter Eisentraut Sernanders vaeg 10:115 peter_e@gmx.net 75262 Uppsala http://yi.org/peter-e/ Sweden
> On Thu, 11 Nov 1999, Bruce Momjian wrote: > > > Can you add a unix-style timestamp for \T? > > Do you mean \echo `date` ? > Oh, very nifty. Never mind. I didn't see that. Seems you have added more powerful flags to take over some of the old flag usage. If you want to remove some of the older psql flags and require them to use your newer syntax that allows more functionality, you can do it. If you want, just print an error message for the old flag showing them the new syntax to use and we can remove the messages after a few releases. However, some of the more popular flags should probably be left in. Maybe it should just be left alone. Not sure. -- Bruce Momjian | http://www.op.net/~candle maillist@candle.pha.pa.us | (610) 853-3000+ If your life is a hard drive, | 830 Blythe Avenue + Christ can be your backup. | Drexel Hill, Pennsylvania19026