Re: Few queries
From: Tamas Bojcan - bojci (bojcan_at_freemail.hu)
Date: 08/26/04
- Next message: Marcox: "Creating a SQL query"
- Previous message: John Bell: "RE: How to handle/strip out Quotes around string columns that can be n"
- In reply to: Amit: "Few queries"
- Next in thread: Uri Dimant: "Re: Few queries"
- Messages sorted by: [ date ] [ thread ]
Date: Thu, 26 Aug 2004 09:06:09 +0200
Hi,
A.) The identity value is numeric(38,0) not integer. This value casted to
the type of identity column which can be tinyint, smallint, int, bigint,
decimal, numeric. You get error message if the identity value greater than
the max. value of the column's datatype. The identity can be negative just
set the increment value to less than zero.
B.) Use four part names => server.database.owner.object
"Amit" <contactamit22@indiatimes.com> wrote in message
news:065c01c48b38$c5ecb3b0$a401280a@phx.gbl...
> Hi,
>
> A] Regarding Identity column values:
> Create table A(id int identity(1,1) Primary key)
> For above table,
> 1. What will happen to the insert statement when the
> identity column value has reached the maximum value
> defined for integer ?
> My answer: Should generate an error message.
>
> 2. Will identity value ever be negative ?
> My answer: NO
>
> B] Can we execute join queries on tables in two different
> databases ?
>
> C] Can we have DML statements in the body of function ?
> My answer: yes but only for table variables declared
> inside the function / in the return type.
>
> Thanks in advance.
> Amit
- Next message: Marcox: "Creating a SQL query"
- Previous message: John Bell: "RE: How to handle/strip out Quotes around string columns that can be n"
- In reply to: Amit: "Few queries"
- Next in thread: Uri Dimant: "Re: Few queries"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|
|