473,503 Members | 9,836 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

How to set default schema name?


Folks,

Is there a way to set a default schema name by setting environment
variable, so that it is set for CLP and any program I run from command line.

Thanks.
--
Hemant Shah /"\ ASCII ribbon campaign
E-mail: No************@xnet.com \ / ---------------------
X against HTML mail
TO REPLY, REMOVE NoJunkMail / \ and postings
FROM MY E-MAIL ADDRESS.
-----------------[DO NOT SEND UNSOLICITED BULK E-MAIL]------------------
I haven't lost my mind, Above opinions are mine only.
it's backed up on tape somewhere. Others can have their own.
Nov 12 '05 #1
4 19338
Is it possible to create a user id that equals the schema name?
Then you just connect to the database with that user id.
Otherwise you have to issue the SET SCHEMA='name' command

Hemant Shah wrote:
Folks,

Is there a way to set a default schema name by setting environment
variable, so that it is set for CLP and any program I run from command line.

Thanks.


--
Anton Versteeg
IBM Certified DB2 Specialist
IBM Netherlands
Nov 12 '05 #2
Ken
You can set a default schema on programs that are prep'ed and bound to
the database. It is either the "collection" and/or the "qualifer"
parameter. It is one of those things that we set-up in a prep and a
bind script some time ago.

I do not know how to do it globally.

Ken
Anton Versteeg <an************@nnll.iibbmm.com> wrote in message news:<40**************@nnll.iibbmm.com>...
Is it possible to create a user id that equals the schema name?
Then you just connect to the database with that user id.
Otherwise you have to issue the SET SCHEMA='name' command

Hemant Shah wrote:
Folks,

Is there a way to set a default schema name by setting environment
variable, so that it is set for CLP and any program I run from command line.

Thanks.

Nov 12 '05 #3
While stranded on information super highway Ken wrote:
You can set a default schema on programs that are prep'ed and bound to
the database. It is either the "collection" and/or the "qualifer"
parameter. It is one of those things that we set-up in a prep and a
bind script some time ago.

I do not know how to do it globally.

Ken
Thanks. I will take a look at it. This might solve most of my problems.


Anton Versteeg <an************@nnll.iibbmm.com> wrote in message news:<40**************@nnll.iibbmm.com>...
Is it possible to create a user id that equals the schema name?
Then you just connect to the database with that user id.
Otherwise you have to issue the SET SCHEMA='name' command

Hemant Shah wrote:
>Folks,
>
> Is there a way to set a default schema name by setting environment
> variable, so that it is set for CLP and any program I run from command line.
>
> Thanks.
>
>
>
>


--
Hemant Shah /"\ ASCII ribbon campaign
E-mail: No************@xnet.com \ / ---------------------
X against HTML mail
TO REPLY, REMOVE NoJunkMail / \ and postings
FROM MY E-MAIL ADDRESS.
-----------------[DO NOT SEND UNSOLICITED BULK E-MAIL]------------------
I haven't lost my mind, Above opinions are mine only.
it's backed up on tape somewhere. Others can have their own.
Nov 12 '05 #4
Ken <lf****@volcanomail.com> wrote:
You can set a default schema on programs that are prep'ed and bound to
the database. It is either the "collection" and/or the "qualifer"
parameter. It is one of those things that we set-up in a prep and a
bind script some time ago.


That works for static SQL. For dynamic, you will have to use SET SCHEMA ...
in your code.

--
Knut Stolze
Information Integration
IBM Germany / University of Jena
Nov 12 '05 #5

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
2701
by: John L. Clark | last post by:
I am curious as to the rationale, and effect, of having default namespaces not applying (directly) to attributes (see http://www.w3.org/TR/REC-xml-names/#defaulting). Given an attribute without a...
4
2914
by: Lénaïc Huard | last post by:
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Hello, I've some namespace problems when defining default values for attributes. My problem seems to come from the fact that the attributes are...
6
2557
by: Martin | last post by:
Hi, I have a xml file like the one below <?xml version="1.0" encoding="utf-8"?><e1 xmlns:e1="http://tempuri.org/Source1.xsd" e1:att1="1" e1:att2="2" e1:rest="345"/> If I try to create a...
12
4923
by: Stefano | last post by:
Hi all, what is the correct use of the "default" attribute in XML Schema? For example: <xs:element name="myProperty" type="xs:string" default="myDefaultValue"/> What can I do with it? What...
7
21293
by: greatcanyon | last post by:
Hi, When I create a new user in DB2, can I set the default schema to an existing schema? The reason I want to do this is that I want to later connect to db2 as this user and access tables...
2
1578
by: Nicolas | last post by:
Hi everybody... In Xerces 2.7.0 it is explicitly stated that, no matter how one removes an attribute (attList->removeNamedItem, attList->removeNamedItemNS, domElement->removeAttributeNode,...
12
8528
by: Plop69 | last post by:
need some help on following: xml file 1 <TEST xmlns="http://test" > <OK>mlkddflmkj</OK> </TEST>
2
3014
by: Mark | last post by:
Hi... I've been trying the .Validate() method on the XmlDocument to validate some xml against a schema, but one thing I noted was that unless the document explicitly declares the schema as a...
0
1026
by: bharadwajrv | last post by:
Hi: This is my simple schema <?xml version="1.0" encoding="UTF-8"?> <xs:schema elementFormDefault="qualified" attributeFormDefault="unqualified" xmlns:xs="http://www.w3.org/2001/XMLSchema">...
0
1251
by: =?Utf-8?B?VmVudQ==?= | last post by:
This is my simple schema ------------------------------------------------------------------------------------ <?xml version="1.0" encoding="UTF-8"?> <xs:schema elementFormDefault="qualified"...
0
7294
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
7361
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
7470
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
5602
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
1
5026
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
4693
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
3183
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
1523
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...
0
403
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.