Current Opinion On UDTs?

Jun 4, 2007

What's the current opinion on UDTs? Are they valuable? Do the benefits outweigh the costs? Are they an absolute no-no? Has there been anything authorative or groundbreaking on the topic since Alex P's blog back in October 2005?



http://weblogs.asp.net/alex_papadimoulis/archive/2005/10/20/428014.aspx



View 4 Replies


ADVERTISEMENT

Tempdb And UDTs

Nov 8, 2000

In my main database I have declared a number of User Defined types for consistency across tables. However, as one might expect, I cannot then use the UDT in stored procs as temporary table datatypes since the UDT is not present in Tempdb. If I have to declare my #temp table columns as the native types, I lose the advantage. What is the preferred way of tackling this - could I create the UDT in model? or run scripts at server startup to create them in tempdb?

View 1 Replies View Related

My SQL CLR UDTs Are Not Displayed Correctly In The Database, Or Are They?

Sep 14, 2007

Hi,

I'm new to SQL CLR programming and have recently implemented a few simple test UDTs. Typically I provide a property called Value and, if applicable, a method to display that value in a different format. For example, I havea UDT representing Australian states: the Value property returns the acronym (e.g. VIC) and the ProperName() method returns the full name (e.g. Victoria).


However, when I do a regular query, say SELECT * FROM Customers, the values in the column in which I am using the UDT are displayed as hex (I believe), for example '0x008064'.


Is this behaviour the result of a faulty implementation on my part or is it just the way SQL Server displays a non-native data type?

Here's the essential implementation code:

[Serializable]
[SqlUserDefinedType(Format.UserDefined, IsByteOrdered = true, MaxByteSize = 58, IsFixedLength = false)]
public struct udt_au_stateId : INullable, IBinarySerialize
{
private bool _isNull;
private AU_StateId _state;
private enum AU_StateId { ACT, NSW, NT, QLD, SA, TAS, VIC, WA }

public void Read(BinaryReader r)
{
SetStateId(r.ReadString());
}

public void Write(BinaryWriter w)
{
w.Write(_state.ToString());
}

public SqlString Value
{
get { return _state.ToString(); }
set
{
if (!SetStateId(value.ToString()))
throw new ArgumentException("'" + value.ToString() + "'" + " is not a valid Australian state or territory.");
}
}

public SqlString ProperName()
{
return GetProperName();
}

public override string ToString()
{
if (_isNull)
return "<NULL>";
else
return _state.ToString();
}

public bool IsNull
{
get { return _isNull; }
}

public static udt_au_stateId Null
{
get
{
udt_au_stateId u = new udt_au_stateId();
u._isNull = true;
return u;
}
}

public static udt_au_stateId Parse(SqlString s)
{
if (s.IsNull)
return Null;
else
{
udt_au_stateId u = new udt_au_stateId();
u.Value = s;
return u;
}
}

/* some implementation details omitted */



Best regards,
Ieyasu

View 6 Replies View Related

Merge Replication: Does It Support UDTs && Defaults

Feb 27, 2003

Hi Everyone,

Can anyone help me with this little problem that im stuck with.
As part of the initial snapshot using merge replication, i am creating the initial schema on the subscriber database however it seems as though it does not like UDDTs or defaults and hence does not create them on the subscribers.

Its looking likely that I may have to create a script which executes on the subscriber which creates the initial schema then use merge replication to transfer data.

Does Merge Replication support UDTs/Defaults? If so how does it work?

Ive search many places though have come up with nothing.

Please help. = (

View 2 Replies View Related

Opinion

Sep 15, 2005

I have 2 tables:
Table 1 has:ID,FName,Lname
Table2 has:ID,PID,PFName,PLName, Flag
PID is a unique number -> (hh:mm:ss)
I need to run an update to table2 by setting the Flag to 1 and also creating PID.
I could use a join query to do this, but I am concern about PID (hh:mm:ss), because it may take less then 1 second to update and I will have duplicate PID.
Any idea what is the best way of doing this?

View 1 Replies View Related

I Got Into This..i Just Need Your Opinion

Nov 14, 2007

Well, its kind of tricky, and i got into this.For example i have a column of zip, all US city state name and abbreviation, preffered name and an alternate name of each city in US, and also non-acceptable name of each preffered name..

Can you give me a hint, how many databse should i used?
for example, i search for a zip code, and the result will be the name of city or an acceptable name of city and there are non-acceptable name too..

well.i just need your opinion..hope you could get into this one.tnx

View 8 Replies View Related

Looking For An Opinion

Nov 3, 2005

This is more a theoretical question so I do not have any DDL (working)to post.Let's say that I have a query which needs to be filtered for specificaccounts while also needing several joins to retrieve additional data.Is it better to so one big SELECT / JOIN / WHERE statement? As inSELECT * FROM T1JOIN T2 ON T2.[Col1] = T1.[Col1]JOIN T3 ON T3.[Col2] = T1.[Col2] AND T3.[Col3] = T1.[Col3]and so on...WHERE T1.[Account] IN ('123', '456', '789')OR is it better to do an inner SELECT / WHERE and pass that to a SELECT/ JOIN? As inSELECT * FROM(SELECT * FROM T1WHERE T1.[Account] IN ('123', '456', '789')) ITJOIN T2 ON T2.[Col1] = IT.[Col1]JOIN T3 ON T3.[Col2] = IT.[Col2] AND T3.[Col3] = IT.[Col3]and so on...First glance logic says that the inner select is the way to go sincethe joins would have less rows to work with, as opposed to joineverything and THEN pulling out what is not needed. But the queryplanner sometimes seems to have a mind of its own... Does it know thatrows will be pulled so it does that first? If I follow the same"structure" with many different queries does in us the same logic allthe time or do I need to try the same thing for each and check it?How does this apply to situations where there is a UNION involved? Do Ido the union and then apply WHERE and JOIN to filter out rows and getadditional data, respectively, or do I filter out rows inside the unionand take the combined set and do the JOINS?SELECT * FROM(SELECT T1.[Col1], T1.[Col2] FROM T1UNION ALLSELECT T2.[Col1], T2.[Col2] FROM T2) CTJOIN T2 ON T2.[Col1] = CT.[Col1]JOIN T3 ON T3.[Col2] = CT.[Col2] AND T3.[Col3] = CT.[Col3]and so on...WHERE CT.[Account] IN ('123', '456', '789')versusSELECT * FROM(SELECT T1.[Col1], T1.[Col2] FROM T1 WHERE T1.[Account] IN ('123','456', '789')UNION ALLSELECT T2.[Col1], T2.[Col2] FROM T2 WHERE T2.[Account] IN ('123','456', '789')) CTJOIN T2 ON T2.[Col1] = CT.[Col1]JOIN T3 ON T3.[Col2] = CT.[Col2] AND T3.[Col3] = CT.[Col3]and so on...

View 2 Replies View Related

Your Opinion On Design

Mar 2, 2000

Hi,
I need your suggestions on a design issue:

I have 2 tables, Customers and Organizations. 1 Customer can be under many organizations. What would be the best way to design the db (2 choices) for performance (around 50000 customers):
1)
-Customer table
-Organization table
-Link Organization & Customer by creating a new tables with the following structure ---> CustomerID, OrgID,

2)
-A Customer tables that has a field called OrgID where the orgID is stored. If the customer has more organization related to him, we add another customer record and we put the new OrgID in the OrgID column. Examples:

Customer Table
--------------
CustomerID--Fname--Lname--Addresss-----OrgID
---------------------------------------------
1 Bob Marley 33 Africa org1
1 Bob Marley 33 Africa org2
1 Bob Marley 33 Africa org3

Please give me your suggestions,

Thank you for your time,

SASAN

View 1 Replies View Related

Join Opinion

Jan 7, 2004

What is the better practice when joining tables in a query example 1 or 2? I've always joined tables together like example 2, but it seems that many people are advocates of example 1. Are there any differences performance wise between the two?

Example 1:
SELECT *
FROM authors AS a INNER JOIN publishers AS p
ON a.city = p.city
ORDER BY a.au_lname DESC

Example 2:
SELECT *
FROM authors AS a, publishers AS p
WHERE a.city = p.city
ORDER BY a.au_lname DESC

View 9 Replies View Related

Need Opinion On New Purchase

Dec 18, 2007

I need to purchase a new computer for a small medical clinic which will basically only have one purpose: to answer to read and write queries to a SQL Server 2005 which is resident on that computer. Queries come from the current 8 stations (up to 14 stations in the future). Most of the time, only 3 stations will be active at a time. Queries are mostly to access patient file information, are not complex and are short-lived.

A friend of mine who owns a computer store just quoted me for a dual quad-core Xeon 5405 2GHz system with Windows Server 2003 10 Cals. I'm concerned about the following:
- What's the use in having 8 cores, each of them running at only
2GHz, when there's really only one service running (SQL Server
2005, likely Express Edition) on the computer. Does SQL Server
have the capability to make use of all cores? Otherwise, why
spend more for Xeon and so many cores instead of a single
C2D running at a faster speed of say 3GHz ?
- What would be the advantage of using a Windows Server over
Windows XP in a peer-to-peer configuration? I don't buy into
the 10 connection limit because the TCPIP.sys file can be
altered to move that limit up, so 14 stations does not trigger
the need for Windows Server in and of itself.

Thanks all!

View 5 Replies View Related

Need Opinion About This Design Thread

Apr 13, 2007

Hi all,
I am having problem with SQL connection at Godaddy where my pool connection gets MAX OUT. When it happens, I cannot access the database.This is the thread about the problem: http://forums.asp.net/thread/1665023.aspx
I just created this with "THREAD". I hope someone who has experiences with thread can give me some advice about my design. This is my first time.
 
static object Locked = new object();
public object ExecuteCommand(string queryStr, string type){     //*************************************************************************************//     // ExecuteCommand: Returns an object //    //*************************************************************************************//     Thread t = null;     lock(Locked)     {          SQLString = queryStr;                    switch(type)          {               case "ExecuteNonQuery":                   t = new Thread(ExecuteNonQuery);                   break;               case "ExecuteScalar":                    t = new Thread(ExecuteScalar);                    break;               case "GetDataReader":                    t = new Thread(GetDataReader);                    break;          }             t.Start();          t.Join();     }     return null;}
First of, does this work at all? It runs, but is it a good design in term of Thread? Since I use LOCK, do I still need the t.Join() function? The switch with the three cases, is that OKAY? Basically, I'm clueless. If you read my other post, you will get an idea what I'm trying to do. Any feedback would be very very appreciated.
Thank you.

View 2 Replies View Related

Opinion On Cube Analysis

Feb 7, 2008

Hi,

I was talking to my boss to day and our report request are not very consistant. We always having someone coming back to change something in our report. We were thinking of useing something called the Cube Analysis. Then it give our employees the raw data for them to run any standard query for themself. We have folks that want a report one way, but then they changed their minds and we are creating yet another report 4 or 5 times. what are your thoughts about this type of database?

View 6 Replies View Related

Need Another Opinion (Database Design)

May 8, 2007

I need some other opinions on whether or not this is considered a proper database design structure.

Here is the relationship...We have PEOPLE, that each can belong to a COMPANY.

PERSON_TABLE
Person_ID
Company_ID

COMPANY_TABLE
Company_ID

Then each person can trust other people of other companies, but can only trust 1 person per company.

My question is this. In order to maintain a constraint of 1 person per company, is it considered OK to add a the redundant column Company_ID to the PERSON_TRUSTED_TABLE(and then creating a composite primary key on the Person_ID/Company_ID) instead of just adding a trigger to the PERSON_TRUSTED_TABLE to uphold the constraint.

PERSON_TRUSTED_TABLE
Person_ID
Trusted_Company_ID
Trusted_Person_ID

I would appreciate anyone's opinion. Thanks so much!

View 5 Replies View Related

I Need A Second Opinion On SQL 2005 Syntax

Apr 25, 2006

I am not that experienced in SQL 2005 and I'm trying to debug a stored proc (written by a far more experienced programmer which is why I'm appending here.)

At the top of the proc is the statement 'DECLARE @BillActualRoom bit'. If I understand correctly this is a local variable.

Later in the code we have the statement

'SELECT @BillActualRoom = 0 FROM BillingOptions WHERE CenterID = @CenterID'

where @CenterID is an input parameter.

The table BillingOptions does have a field called 'BillActualRoom' and it is a bit.

My question is this: Does this SQL statement make any sense at all? (My gut reaction is no but I'd like a second opinion. Can't get any consensus in the office.)

I would think that putting a local variable in like this would mean that @BillActualRoom is always equal to 0.

View 5 Replies View Related

%disk Time Opinion Requested

Mar 21, 2003

Trying to deal with a user complaint of slowness. Many variables looked at which look normal (Buffer cache, queue length,memory). Probably looks like a network issue. My question is what people consider acceptable when it comes to %disk time. My %disk time has increased from an average of 20% to 33% in recent months. My average disk read and average disk write have both been less than one. MY research has showed that more than 55% %disk time for ten minutes is considered a problem. Not there yet but seem to be slowly getting there. THe app running against my server is vendor written so can't change, also running log shipping which is probably inflating the numbers a little.
Any opinions appreciated.

View 1 Replies View Related

% Processor And % User Time Opinion

May 26, 2004

I have a server with little control over most of the codeset and db design. Recently I have seen both the Processor - %Processor time and Processor - % User time go fom about 6.3 to about 24.3. The system queue length has also gone from about .2 to 1.1. In my humble opinion both of the are signs of a problem coming (luckily the cache hit ratio is still sitting at about 99%). I have been running profiler to catch the things that take more that 4500 MS, and I can probably tie the 2 together. Any opinions, or real world comparisons appreciated

View 3 Replies View Related

Opinion Requested On Developer Permissions

Feb 27, 2004

We are trying to restrict developer permissions in our development environment. One thought is to add developers to db_datareader, db_datawriter, db_ddladmin, db_securityadmin and then revoke various permissions from ddladmin and securityadmin. The goal is to allow developer to create stored procedures and assign permissions to the stored procedures.

Another option is to place all developers in the same role and ask them to create all procedures using that role name (ex: dev_role.sp_procedurename). By doing this each developer will be able to run stored procedures created by another developer. The down side is the permissions do not match Model Office/User Test and Production.

Any suggestions on how to handle this situation?

Thanks, Dave

View 2 Replies View Related

Opinion/Standard For Join Condition

Jul 30, 2007

Hi,

I was having a conversation with another developer about the order that the join conditions are placed. More specifically, about the order the tables are referenced in the join condition. There are two ways to do it, for example:-- Here the table that is referenced first was "declared" first.
SELECT*
FROM
Logon
LEFT OUTER JOIN
Thread
ON Logon.LogonID = Thread.LogonID
LEFT OUTER JOIN
Message
ON Thread.ThreadID = Message.ThreadID

-- Here the table that is referenced first is the table being joined directly above it.
SELECT*
FROM
Logon
LEFT OUTER JOIN
Thread
ON Thread.LogonID = Logon.LogonID
LEFT OUTER JOIN
Message
ON Message.ThreadID = Thread.ThreadID
I realize this is not that big of a deal, but I was wondering if anyone had a good/valid reason for doing one versus the other.

Just curious,

-Ryan

View 10 Replies View Related

Want Expert Opinion On A Way Of Storing 'relations'

Jul 20, 2005

i've a database where relations are hold in a special way which the projectleaders think of as "performant and uncomplicated" but which is veryquestionable to me:------------------------------------------------Table [Attributes]Fields [AttributeID] and [AttributeText]Table [Objects]Fields object stuff.... and [AttributeIDs] (varchar with 0-20 ids usually)in AttributeIDs there is a backslash separted list of Attribute-IDs like'3412278'so to get 20 object with a special attribute (which we need often) we doSELECT TOP 20 *FROM ObjectsINNER JOIN AttributesON (Objects.AttributeIDs LIKE ('%' + (CAST AttributeID AS varchar) + '\%'))ORDER BY ObjectTextps: to store data we need for communication we include a dozen of fields in*every* table and its content makes about 100 bytes/record------------------------------------------------i would do this stuff with a table to store the object/attributecorrelations.could someone tell me if that stuff makes any sense to an expert and how tovaluate it in regard of performance(we have big customers where that *is* anissue), design, scalability, pragmatism and sense ;)thanks in advance,ViperDK

View 1 Replies View Related

SSIS - DataFlow Performance (need Opinion)

Jul 1, 2007

Dear friends,

I need your feedback, tips and opinions to improve my dataflow described in my blog.

http://pedrocgd.blogspot.com/2007/07/ssis-dataflow-performance-i.html

Thanks!!

View 8 Replies View Related

Need An Opinion: Access Vs. SQL Server Express Or Another Alternative?

Apr 30, 2007

I inherited this website from a previous developer that uses an Access DB as a backend.  Ugh.  Apparently, he was extremely limited in what databases he could use.  The website is filled with problems related to connecting to this database, which is no surprise.  Most of them are related to permissions to the database file, multiple user access, etc. I am thinking about moving this to a SQL Server Express DB and upgrading the site to the 2.0 framework.  Most of my experience is in SQL Server, but since they can't, or won't, pay for the SQL Server Database, is this a good solution?  I've considered using MySQL as well, but their host won't provide support for this.  Are there any other recommended alternatives?

View 2 Replies View Related

Opinion On Preventing Duplicate Record Insertion

Oct 26, 2007

Hi, i need an opinion on this...to prevent the duplicate record in db,i am using unique constraints for a column or combination of column as the case may be.By reading this  article http://aspalliance.com/687_Preventing_Duplicate_Record_Insertion_on_Page_Refresh.5 , i get the feeling that its not such a good idea..i am wondering,what does it imply?Does it mean that unique constraints are not reliable enough?Does it mean,it may break and let the duplicate record inserted,even though its not suppose to?I am using SQL server 2005
I have read Dino's article on dup recs and i have still not understood it completely.. i am looking for some not so complex ,full proof method,to prevent duplicate record insertion by clicking refresh or multiple (careless)clicking on submit....thanks ..

View 2 Replies View Related

Opinion Requested: Multi-Table Design

Dec 23, 2004

I have about a 35000 record table. There are about 14 entries in this table that relate to "sections". Each of these sections can have up to 20 values. This lends itself to a design like:


big_table [one-to-one] big_table_has_sections [many-to-many] sections


or, more concretely:


BuildingConstructionType
relates to
ConstructionHasTypes
relates to
Types


Where BuildingConstructionType is one of 14 fields in the 35000 record "big" table, ConstructionHasTypes is the one-to-one intermediary relation that relates many-to-many with Types (the sections).

Unfortunately, with 35000 records, this big_table_has_sections seems like it might bloat. Is this a good solution?

View 2 Replies View Related

Opinion About Design Needed (splitting String Data)

Dec 14, 2006

Hi to everyone,My problem is, that I'm not so quite sure, which way should I go.The user is inputing by second part application a long string (let'ssay 128 characters), which are separated by semiclon.Example:A20;BU;AC40;MA50;E;E;IC;GREENNow: each from this position, is already defined in any other table, asa separate record. These are the keys lets say. It means, a have someproperities for A20, BU, aso.Because this long inputed string, is a property of device (whih alsohas a lot of different properities) I could do two different ways ofstoring data:1. By writing, in SP, just encapsulate each of the position separatedby semicolon, and write into a different table with index of device,and the position in long stirng nearly in this way:Major device data tableID AnyData1 AnyData2 ... AnyData3123 MZD12 XX77 .... any comment text124 MZD13 XY55 ... any other commentString data Tablefk_deviceId position value123 1 A20123 2 BU123 3 AC40.....123 8 GREENThe device table, contains also a pointer (position), which mightchange, to "hglight" specified position.Then, I can very easly find all necessary data. The problem is, I needto move the device record data (from other table) very often into otherhistory table (by each update). That will mean, that I also need tomove all these records from 1 -8 for example to a separate historytable, holding the index for a history device dataset. This is a littleinconvinience in this, and in my opinion, it will use to much storagedata, and by programming, I need always to shift this properities intohistory table, whith indexes to a history table of other properities.2. Table will be build nearly in this way:Major device data tableID AnyData1 AnyData2 ... AnyData3 stringProperty pointer123 MZD12 XX77 .... any comment text A20;BU;AC40;MA50;E;E;IC;GREEN 3124 MZD13 XY55 ... any other comment A20;BU;AC40;MA50;E;E;IC;GREEN 2By writng into device table, there will be just a additional field forthis string, and I will have a function, which according to specifiedpointer, will get me the string part on the fly, while I need it.This will not require the other table, and will reduce the amout ofdata, not a lot ... but always.This solution, has a inconvinance, that it will be not so fast doing asearch over the part of this strings, while there will be no real indexon this.If I woould like to search all devices, by which the curent pointervalue is equal GREEN, then I need to use function for getting thevalue, and this one will be not indexed, means, by a lot amount ofdata, might be slow.I would like to know Your opinion about booth solutions.Also, if you might point me the other problems with any of thissolution, I might not have noticed.With Best RegardsMatik

View 7 Replies View Related

Get Rows Between Current Date And Current Time

Jun 8, 2008

I've this query
SELECT
t1.ID, t1.Date, t1.Time,
t1.VALUE
FROM RESULT WHERE t1.Date>=CONVERT(VARCHAR(10),DATEADD(d,-7,GETDATE()),101) AND
t1.Date<CONVERT(VARCHAR(10), GETDATE(), 101)

Let's say, current date is 8 AUG 2005 and current time is 2045
So, i will get
ID | Date (this is datetime) | Time (this is integer) | Value
--------------------------------------------------
204 | 8/1/2005| 2359 | 90
205 | 8/1/2005| 2250 | 99
206 | 8/1/2005| 1950 | 88
...
...
207 | 8/7/2005| 1845 | 77
208 | 8/7/2005| 2255 | 77
209 | 8/7/2005| 2140 | 77

Can someone can show me to filter data between
t1.Date>=CONVERT(VARCHAR(10),DATEADD(d,-7,GETDATE()),101) AND TIME>=CurrentTime
t1.Date<CONVERT(VARCHAR(10), GETDATE(), 101) AND TIME<=CurrentTime

If current date is 8 AUG 2005 and current time is 2045, so the result shown as follow

ID | Date (this is datetime) | Time (this is integer) | Value
--------------------------------------------------
204 | 8/1/2005| 2359 | 90
205 | 8/1/2005| 2250 | 99
...
...
207 | 8/7/2005| 1845 | 77

I only have this query,
SELECT
t1.ID, t1.Date, t1.Time,
t1.VALUE
FROM RESULT WHERE t1.Date>=CONVERT(VARCHAR(10),DATEADD(d,-7,GETDATE()),101) AND
t1.Date<CONVERT(VARCHAR(10), GETDATE(), 101)

lack of idea to put the TIME condition.

Plz help me..

View 14 Replies View Related

Check If Date Is Current Date And Stay Current

Apr 25, 2008

Hi,

I'm making some sort of application where people can add their resume.
They also need something to add places where they have worked or currently are working.

I have a form where they can add this and i add this experience using the following stored procedure:


GO
SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
create procedure [dbo].[sp_Insert_Experience]
@ExperienceId uniqueidentifier,
@ExperienceEmployee nvarchar(100),
@ExperienceFrom datetime,
@ExperienceUntil datetime,
@ExperienceQualifications nvarchar(250),
@ExperienceTechnologies nvarchar(250),
@ExperienceTasks nvarchar(250)
as
insert into Experiences
values(@ExperienceId,@ExperienceEmployee,@ExperienceFrom,@ExperienceUntil,@ExperienceQualifications,
@ExperienceTechnologies,@ExperienceTasks);


It must be possible to add the place where they currently are working. Then the ExperienceUntil has to be something like still going on. Then I decided that the user then had to set the current date.

But what I want is the following, I want that the ExperienceUntil keeps updating automatically, like everytime i get that record, it has to have current date.

Is this possible ?

But if the ExperienceUntil isn't the current date , it just had to take the supplied parameter date.

View 7 Replies View Related

Current Row No?

Mar 14, 2007

i know there is a function to count number of rows in a group, but is there anyway of numbering each row?

So that I can use =Last(ReportIems("norow") to find the last row on the page????

Thanks

View 3 Replies View Related

While And Current Value

Apr 18, 2008



I have following query
....

while ( select fieldID from table where age <> 2)

begin


how I can get current value of "fieldID" for future calculations or operations?
like

insert into othertable values (fieldID, .....)

end

View 2 Replies View Related

Get The Current Year Using SQL

Aug 13, 2004

Hi everyone,

Currenly, I'm getting the current year in my code, and passing this to my stored procedure.

I'm sure there's a way just to get the current year (ie '2004') just by using SQL.

I was just about to post this question here when I did a bit more digging around and found my solution:

DATEPART(yyyy, GETDATE())

This will get the year.

Hope this helps someone searching for the answer!

View 2 Replies View Related

Appending Current Row ID

Dec 19, 2005

I am trying to append the current row ID to a string I am trying to
insert via a sproc. I have retrieved the @@Identity and I am passing it
into a class with a parameter and calling it using:

Listings.UpdateDB AddNewListing = new Listings.UpdateDB();

AddNewListing.InsertListing (Bathrooms.Text, Bedrooms.Text,
Description.Text, Features.ToString(), Address.Text, Price.Text, FN);

I would like to add the current row ID to "FN" like:

Listings.UpdateDB AddNewListing = new Listings.UpdateDB();

AddNewListing.InsertListing(Bathrooms.Text, Bedrooms.Text,
Description.Text, Features.ToString(), Address.Text, Price.Text, FN +
ID);


Thanks in advance,
Justin.

View 1 Replies View Related

Current SQL Statement

Sep 25, 2001

My backup fails in the night, because of a non logged operation being executed at the same instant. I am interested in finding out the statement that is causing the problem. What would be the best way to do that?

View 2 Replies View Related

Current Activity

Apr 17, 2000

I have registered a server on to my client machine successfully,but I am not finding the current activity item in the management folder on EM.How do I see the current activity on the server.Do I need to be SA for that server?My machine has NT workstation with SQL server 7.0 on it.Any one to help?

View 1 Replies View Related

Current Activity Not Available? 6.5

Aug 12, 1999

When viewing Current Activity, nothing shows up.

If i run sp_who, the return is normal.

If I run sp_who2, the following message is returned. (it also is returned randomly while using function in EM such as Backup/Restore.)

Msg 268, Level 16, State 1
You cannot run SELECT INTO in this database. The DBO would have to run sp_dboption to enable this option.


What is it??? It's buggin me......

Dano

p.s. I remember a similar problem in the past, it had to do with turning truncate on checkpoint in one of the system databases msdb/master/tempdb or something like that. I turned off all Trunc. and Select/Bulk options on these...

View 2 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved