08-10-2006
Tmarkil-
Thanks so much for the fast reply....!
I should have looked into the news group first, the answer was there
10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
I am trying to strip all leading and trailing spaces of a shell variable using either awk or sed or any other utility, however unscuccessful and need your help.
echo $SH_VAR | command_line Syntax.
The SH_VAR contains embedded spaces which needs to be preserved. I need only for the leading and... (6 Replies)
Discussion started by: jerardfjay
6 Replies
2. UNIX for Dummies Questions & Answers
Hi! I'm fairly new to UNIX so don't mention that my question is stupid.
I have many problems with spaces in folders and files names.
Let's say I have the following files:
toto.txt
this is toto.txt
in /usr/local/this is a test/
Why the following commands works:
ls "/usr/local/this... (2 Replies)
Discussion started by: darkyoda2
2 Replies
3. UNIX for Advanced & Expert Users
Hi,
How can I remove the unwanted spaces in the line.
123456 789 ABC DEF. - I wanna remove the sapces in this line, I need the output 123456789ABCDEF.
Pls help me...... (3 Replies)
Discussion started by: sharif
3 Replies
4. UNIX for Dummies Questions & Answers
Hi,
I have a problem where I need to append few spaces(say 10 spaces) for each line in a file whose length is say(100 chars) and others leave as it is.
I tried to find the length of each line and then if the length is say 100 chars then tried to write those lines into another file and use a sed... (17 Replies)
Discussion started by: prathima
17 Replies
5. Shell Programming and Scripting
Hi All,
I have a comma seperated file.
I wanna remove the spaces from column 2. I mean i don't wanna remove the spaces those are presnt in column 1.
ex:
emp name, emp no, salary
abc k, abc 11, 1000 00
bhk s, bhk 22, 2000 00
the output should be:
emp name, emp no, salary
abc k, abc11,... (4 Replies)
Discussion started by: javeed7
4 Replies
6. Shell Programming and Scripting
Hello All,
I am trying to remove all tabspaces and all blankspaces from my file using sed & awk, but not getting proper code. Please help me out.
My file is like this (<b> means one blank space, <t> means one tab space)-
$ cat file
NARESH<b><b><b>KUMAR<t><t>PRADHAN... (3 Replies)
Discussion started by: NARESH1302
3 Replies
7. Shell Programming and Scripting
Dear Friends,
I have a flat file from which I want to remove single "space". And, wherever two spaces are provided it should replace it by only one space.
E.g.
I have
N A T I O N A L E D U C A T I O N F O R O R G AN I S A T I ON S
I want
NATIONAL EDUCATION FOR ORGANISATIONS
Please... (5 Replies)
Discussion started by: anushree.a
5 Replies
8. Shell Programming and Scripting
I'm having a problem with this....
---------------------------------------------------
#!/bin/bash
SPKTAG=" | festival --tts"
echo "Welcome to my shell program" "$SPKTAG";
---------------------------------------------------
I have a variable call SPKTAG " | festival --tts" and I... (2 Replies)
Discussion started by: digitalviking
2 Replies
9. Shell Programming and Scripting
Input:
TCAMPBMG0064X344F4E1 1 47552 85.280 557.600 11300
TCAMPBMG0064X352F8E1 1 61265 85.280 718.400 11463
TCAMPBMG0064X344F4E1 1 47552 85.280 557.600 11300
TCAMPBMG0064X352F8E1 1 61265 ... (2 Replies)
Discussion started by: satish1222
2 Replies
10. Shell Programming and Scripting
Hi I have a script which runs the isql command and takes the output in a xls file.
Is there a way to trim the spaces(leading and trailing) from all the values in the column of the xls sheet? (6 Replies)
Discussion started by: Sharma331
6 Replies
LEARN ABOUT SUSE
create_schema
CREATE
SCHEMA(7) SQL Commands CREATE SCHEMA(7)
NAME
CREATE SCHEMA - define a new schema
SYNOPSIS
CREATE SCHEMA schemaname [ AUTHORIZATION username ] [ schema_element [ ... ] ]
CREATE SCHEMA AUTHORIZATION username [ schema_element [ ... ] ]
DESCRIPTION
CREATE SCHEMA enters a new schema into the current database. The schema name must be distinct from the name of any existing schema in the
current database.
A schema is essentially a namespace: it contains named objects (tables, data types, functions, and operators) whose names can duplicate
those of other objects existing in other schemas. Named objects are accessed either by ``qualifying'' their names with the schema name as a
prefix, or by setting a search path that includes the desired schema(s). A CREATE command specifying an unqualified object name creates the
object in the current schema (the one at the front of the search path, which can be determined with the function current_schema).
Optionally, CREATE SCHEMA can include subcommands to create objects within the new schema. The subcommands are treated essentially the same
as separate commands issued after creating the schema, except that if the AUTHORIZATION clause is used, all the created objects will be
owned by that user.
PARAMETERS
schemaname
The name of a schema to be created. If this is omitted, the user name is used as the schema name. The name cannot begin with pg_, as
such names are reserved for system schemas.
username
The name of the user who will own the schema. If omitted, defaults to the user executing the command. Only superusers can create
schemas owned by users other than themselves.
schema_element
An SQL statement defining an object to be created within the schema. Currently, only CREATE TABLE, CREATE VIEW, CREATE INDEX, CREATE
SEQUENCE, CREATE TRIGGER and GRANT are accepted as clauses within CREATE SCHEMA. Other kinds of objects may be created in separate
commands after the schema is created.
NOTES
To create a schema, the invoking user must have the CREATE privilege for the current database. (Of course, superusers bypass this check.)
EXAMPLES
Create a schema:
CREATE SCHEMA myschema;
Create a schema for user joe; the schema will also be named joe:
CREATE SCHEMA AUTHORIZATION joe;
Create a schema and create a table and view within it:
CREATE SCHEMA hollywood
CREATE TABLE films (title text, release date, awards text[])
CREATE VIEW winners AS
SELECT title, release FROM films WHERE awards IS NOT NULL;
Notice that the individual subcommands do not end with semicolons.
The following is an equivalent way of accomplishing the same result:
CREATE SCHEMA hollywood;
CREATE TABLE hollywood.films (title text, release date, awards text[]);
CREATE VIEW hollywood.winners AS
SELECT title, release FROM hollywood.films WHERE awards IS NOT NULL;
COMPATIBILITY
The SQL standard allows a DEFAULT CHARACTER SET clause in CREATE SCHEMA, as well as more subcommand types than are presently accepted by
PostgreSQL.
The SQL standard specifies that the subcommands in CREATE SCHEMA can appear in any order. The present PostgreSQL implementation does not
handle all cases of forward references in subcommands; it might sometimes be necessary to reorder the subcommands in order to avoid forward
references.
According to the SQL standard, the owner of a schema always owns all objects within it. PostgreSQL allows schemas to contain objects owned
by users other than the schema owner. This can happen only if the schema owner grants the CREATE privilege on his schema to someone else.
SEE ALSO
ALTER SCHEMA [alter_schema(7)], DROP SCHEMA [drop_schema(7)]
SQL - Language Statements 2010-05-14 CREATE SCHEMA(7)