Can You Tell Me Why The Char ?? In SQL Server2000,Windows XP?

Jan 18, 2005

HI,Thank you to pay attention to this thread.i am chinese,may be i coudln't say my problem clearly,it's.....





okay,i use the TextBox,SQL Server 2000,i fill the TextBox as Chinese,then,I use the T-Sql INSERT to Finish Inserting A record,but when i open the SQL Server 2000,i find that the char showed in field as the char '???',i don't understand what happened,if the fault of UnicodeEncoding?can you help me? Thx~!

View 4 Replies


ADVERTISEMENT

Installing SQL Server2000 / Windows 2003 Server

Jul 14, 2004

I am going to start installing sql server soon, do I have to have IIS installed? Is it a requirement?

Thanks.

View 2 Replies View Related

UPGRADE FROM SERVER7,OS NT To SERVER2000 And WINDOWS 2000

Aug 11, 2004

Hello,
I have to do an upgrade from server 7 and OS NT to server2000 and windows 2000. Has anyone had any problems while doing this ? Please list the steps taken for the upgrade if you can.
Thanks

View 1 Replies View Related

How To Retrieve The Char(1) Column From SQL Server With Dbbind() Function In Windows C Programming?

May 10, 2007

I have used the following Windows C codes to retrieve records from the bus_newjob table in SQL server:



==========================================================

// construct command buffer to be sent to the SQL server
dbcmd( dbproc, ( char * )"select job_number, job_type," );
dbcmd( dbproc, ( char * )" disp_type, disp_status," );
dbcmd( dbproc, ( char * )" start_time, end_time," );
dbcmd( dbproc, ( char * )" pickup_point, destination," );
dbcmd( dbproc, ( char * )" veh_plate, remark," );
dbcmd( dbproc, ( char * )" customer, cust_contact_person," );
dbcmd( dbproc, ( char * )" cust_contact_number, cust_details" );
dbcmd( dbproc, ( char * )" from bus_newjob" );
dbcmd( dbproc, ( char * )" where disp_status = 0" );
dbcmd( dbproc, ( char * )" order by job_number asc" );

result_code = dbsqlexec( dbproc ); // send command buffer to SQL server

// now check the results from the SQL server
while( ( result_code = dbresults( dbproc ) ) != NO_MORE_RESULTS )
{
if( result_code == SUCCEED )
{
memset( ( char * )&disp_job, 0, sizeof( DISPATCH_NEWJOB ) );
dbbind( dbproc, 1, INTBIND, ( DBINT )0, ( LPBYTE )&disp_job.new_job.job_number );
dbbind( dbproc, 2, NTBSTRINGBIND, ( DBINT )0, ( LPBYTE )&disp_job.new_job.job_type );
dbbind( dbproc, 3, INTBIND, ( DBINT )0, ( LPBYTE )&disp_job.new_job.disp_type );
dbbind( dbproc, 4, INTBIND, ( DBINT )0, ( LPBYTE )&disp_job.new_job.disp_status );
dbbind( dbproc, 5, NTBSTRINGBIND, ( DBINT )0, ( LPBYTE )&disp_job.new_job.start_time );
dbbind( dbproc, 6, NTBSTRINGBIND, ( DBINT )0, ( LPBYTE )&disp_job.new_job.end_time );
dbbind( dbproc, 7, NTBSTRINGBIND, ( DBINT )0, ( LPBYTE )&disp_job.new_job.pickup_point );
dbbind( dbproc, 8, NTBSTRINGBIND, ( DBINT )0, ( LPBYTE )&disp_job.new_job.destination );
dbbind( dbproc, 9, NTBSTRINGBIND, ( DBINT )0, ( LPBYTE )&disp_job.new_job.veh_plate );
dbbind( dbproc, 10, NTBSTRINGBIND, ( DBINT )0, ( LPBYTE )&disp_job.new_job.remark );
dbbind( dbproc, 11, NTBSTRINGBIND, ( DBINT )0, ( LPBYTE )&disp_job.new_job.customer );
dbbind( dbproc, 12, NTBSTRINGBIND, ( DBINT )0, ( LPBYTE )&disp_job.new_job.cust_contact_person );
dbbind( dbproc, 13, NTBSTRINGBIND, ( DBINT )0, ( LPBYTE )&disp_job.new_job.cust_contact_number );
dbbind( dbproc, 14, NTBSTRINGBIND, ( DBINT )0, ( LPBYTE )&disp_job.new_job.cust_details );

// now process the rows
while( dbnextrow( dbproc ) != NO_MORE_ROWS )
{
new_job = malloc( sizeof( DISPATCH_NEWJOB ) );
if( !new_job )
return( 0 );
memcpy( ( char * )new_job, ( char * )&disp_job, sizeof( DISPATCH_NEWJOB ) );
append_to_list( &Read_Job_List, new_job );
}
}
else
{
sprintf( str, "Results Failed, result_code = %d", result_code );
log_str( str );
break;
}
==========================================================



where the job_type columIn is of the char(1) type, NTBSTRINGBIND is the vartype argument in the dbbind() function.



However, what I have gotten is nothing more than a null string from the job_type column. I have alternatively changed the vartype argument to STRINGBIND, CHARBIND and even INTBIND, but the results are the same.



Who can tell me the tricks to retrieve a char(1) column from SQL server?



View 1 Replies View Related

How To Substring From 12 Char To 8 Char Itemid

Jun 19, 2008

Hi,


alter PROCEDURE [dbo].[PPUpdateIWDetails]

(
@CompanyID NVARCHAR(36),
@DivisionID NVARCHAR(36),
@DepartmentID NVARCHAR(36),
@ItemID NVARCHAR(36),
@OrderNo NVARCHAR(36),
@LineNo NVARCHAR(36),
@TAllotedQty Numeric,
@EmployeeID NVARCHAR(36),
@Trndate datetime
)
AS
BEGIN
By default iam passing 12 char itemid as parameter...

Here iam selecting the itemid from InventoryLedger -if it is 8 char than this query should be executed
IF EXISTS(SELECT ItemID FROM InventoryLedger WHERE TransDate=@Trndate AND ItemID=@ItemID AND ILLineNumber =@LineNo AND TransNumber=@OrderNo AND TransactionType='Production' AND CompanyID=@CompanyID AND DivisionID= @DivisionID AND DepartmentID=@DepartmentID)

BEGIN
DECLARE @Qty INT

select @Qty =QUANTITY from inventoryledger WHERE TransDate=@Trndate AND ItemID=@ItemID AND ILLineNumber =@LineNo AND TransNumber=@OrderNo AND TransactionType='Production' AND CompanyID=@CompanyID AND DivisionID= @DivisionID AND DepartmentID=@DepartmentID
select qtyonhand=qtyonhand+@Qty from InventoryByWareHouse where ItemID=@ItemID
END

Here iam selecting the itemid from InventoryLedger -if it is 12 char than this query should be executed(both queries are same)
IF EXISTS(SELECT ItemID FROM InventoryLedger WHERE TransDate=@Trndate AND ItemID=@ItemID AND ILLineNumber =@LineNo AND TransNumber=@OrderNo AND TransactionType='Production' AND CompanyID=@CompanyID AND DivisionID= @DivisionID AND DepartmentID=@DepartmentID)

BEGIN
DECLARE @Qty INT

select @Qty =QUANTITY from inventoryledger WHERE TransDate=@Trndate AND ItemID=@ItemID AND ILLineNumber =@LineNo AND TransNumber=@OrderNo AND TransactionType='Production' AND CompanyID=@CompanyID AND DivisionID= @DivisionID AND DepartmentID=@DepartmentID
select qtyonhand=qtyonhand+@Qty from InventoryByWareHouse where ItemID=@ItemID
END

View 11 Replies View Related

Char(1) And Char(2) Take Same Space?

Aug 21, 2007

I create two tables:

create table table1
(
col1 char(1)
)

go

create table table2
(
col2 char(2)
)

go

I add some records to two tables after createing operation completed.

Then i use dbcc page command to oversee the structures of data page in two tables.
I found some interest things:
The rows in two tabes take up same space:9 bytes

You can see the "9" on top of the data, for example:Slot 0, Offset 0x60, Length 9, DumpStyle BYTE
or calculate from the offset array



Any suggestions?

View 14 Replies View Related

SQL Server2000

Aug 27, 2007

When I try to install MS SQl server2000 on windows XP machine,it says the server component is not supported by OS.What should I do to get it run on my machine?

View 3 Replies View Related

A New BUG Id Sql Server2000

Feb 3, 2008

Hi,
I'm Arash Baseri a Sql Server2000 developer and mail you from Dubai (U.A.E). I have a problem in Sql Server locking table. My problem is not reasonable so the more I researched the more I understand it is not my problem .it is a bug in Sql Server2000.
Now I explain the situation:
I have two tables (Table A and Table B).Table A has a clustered index on col1 and col2, Table B has a clustered index on col1 and col2. I join these tables and update col3 in table A, like this
begin tran
insert [Table A]
select * from Arshiv_Master where Col1 between 26001 AND 26001

Update AI31 set Col3=Case
when 1=1 then 1
Else 0 End
From [Table A]AI5, [Table B]AI31
where AI5.Col1=AI31.Col1 And AI31.Col1 Between 26001 And 26001
/* intentionally I didn't rollback or commit transaction to hold locks on table*/
In another connection I execute this query and I face "Lock request timeout period exceeded" error message.
set lock_timeout 1
set transaction isolation level read uncommitted

Update AI31 set Col3=Case
when 1=1 then 0
Else 0 End
From [Table A] AI5, [Table B] AI31 where AI5.Col1=AI31.Col1 and AI31.Col1 between 45018 And 60000
Now the most interesting part is here .when I use a smaller data range for Col1 no error message is shown. A query like this
set lock_timeout 1
set transaction isolation level read uncommitted

Update AI31 set Col3=Case
when 1=1 then 0
Else 0 End
From [Table A] AI5, [Table B] AI31 where AI5.Col1=AI31.Col1 and AI31.Col1 between 45018 And 50000
As you see the difference between the last two queries is on WHERE clause especially on data rages of Col1.
As you know Sql Server 2000 has row level lock and when I acquire a lock on a record the other records are free. So what's wrong with Sql Server that assumes the others records are locked. I tested this situation in Sql Server 2005 and this problem was not seen so I think it's a bug in Sql Server 2000.Who can help me about this problem?

View 1 Replies View Related

A New BUG In SQL SERVER2000

Feb 2, 2008


Hi,
I'm Arash Baseri a Sql Server2000 developer and mail you from Dubai (U.A.E). I have a problem in Sql Server locking table. My problem is not reasonable so the more I researched the more I understand it is not my problem .it is a bug in Sql Server2000.
Now I explain the situation:
I have two tables (Table A and Table B).Table A has a clustered index on col1 and col2, Table B has a clustered index on col1 and col2. I join these tables and update col3 in table A, like this
begin tran
insert [Table A]
select * from Arshiv_Master where Col1 between 26001 AND 26001

Update AI31 set Col3=Case
when 1=1 then 1
Else 0 End
From [Table A]AI5, [Table B]AI31
where AI5.Col1=AI31.Col1 And AI31.Col1 Between 26001 And 26001
/* intentionally I didn't rollback or commit transaction to hold locks on table*/
In another connection I execute this query and I face "Lock request timeout period exceeded" error message.
set lock_timeout 1
set transaction isolation level read uncommitted

Update AI31 set Col3=Case
when 1=1 then 0
Else 0 End
From [Table A] AI5, [Table B] AI31 where AI5.Col1=AI31.Col1 and AI31.Col1 between 45018 And 60000
Now the most interesting part is here .when I use a smaller data range for Col1 no error message is shown. A query like this
set lock_timeout 1
set transaction isolation level read uncommitted

Update AI31 set Col3=Case
when 1=1 then 0
Else 0 End
From [Table A] AI5, [Table B] AI31 where AI5.Col1=AI31.Col1 and AI31.Col1 between 45018 And 50000
As you see the difference between the last two queries is on WHERE clause especially on data rages of Col1.
As you know Sql Server 2000 has row level lock and when I acquire a lock on a record the other records are free. So what's wrong with Sql Server that assumes the others records are locked. I tested this situation in Sql Server 2005 and this problem was not seen so I think it's a bug in Sql Server 2000.Who can help me about this problem?

View 1 Replies View Related

Access - SQL Server2000

Oct 11, 2001

HI,
I have a application which has Access as Front end and SQLServer as BackEnd.
I have a table which has student details.

Table Fields are:
Record#,FirstName,LastName,MiddleName,Address,City ,State,Pin,.....
The table has about 1200 records.

Every Thing works fine but in the front end when i try to do a search by
FirstName it is VERY SLOW.But it is okey if i search by the Record#.
I need to search by lastname or Firstname and speed up the process.

Any Help will be appreciated,
Thanks,
Rang.

View 1 Replies View Related

Why Should I Upgrade To SQL Server2000 ?

Apr 5, 2001

What are the experiences of those who have upgraded to

View 2 Replies View Related

Why Should I Upgrade To SQL Server2000 ?

Apr 5, 2001

What are the experiences of those who have upgraded to SQL Server 2000?
I am writing a paper for my company and wish to list features of SQL Server 2000 from a user/developer/business aspect. We are on
SQL Server 6.5 and I need to highlight the advantages and disadvatages of upgrading.

Thanks

Jeff

View 7 Replies View Related

Log Shipping In SQL Server2000

Jun 11, 2001

Hi everybody,

I configured Logshipping in sql server 2000(Enterprise edition).in destination server copy and restore is failing(but there is no error).Out ofsync threshold value is set 27 minutes, after 27 minutes i found the error message in sql server error logs "The log shipping destination HARSHA.Northwind1 is out of sync by 27 minutes..

Any body help me

View 2 Replies View Related

How To Move From A2K To SQL Server2000

Aug 27, 2004

Hi gang,

Just trying to get some information on what is required to migrate from Access 2000 to SQL Server?? Is it pretty difficult to do? Are there any changes to the data or structure that is needed? Is SQL Server more secure? What about MSDE instead of SQL?? I'm just needing some tips and info on what to expect and all as I think we are going there kinda soon. I can do many things in Access but not sure how to go about them in SQL Server? Can you also do reports from there as well?

Inquiring mind wants to know
have a nice one,
Bud

View 3 Replies View Related

Help-Can I Use 4 GB Memory By SQL Server2000?

Dec 18, 2006

There is a Server with 4G Memory. I installed a SQL Server 2000 standardversion on it.I heard that SQLServer2000 could use only up to 2GB memory. Is it true?How can I use those 4GB memory? I can not upgrade to SQL Server 2005 orother version because i don't want to take this risk.Thank you very much.

View 8 Replies View Related

SSIS And Sql Server2000

Oct 31, 2006

Hi, Is it possible to use ssis for the etl processes and still have an existing 2000 db? For e.g. CanI create a ssis pkg and use the xml task to download data to a 2000 db.

View 4 Replies View Related

Analysis Manager Sql Server2000

Feb 3, 2005

dear sir/madam,

i have to create a cube in analysis manager in sql server 2000.as i want to see the data according to my organisation levels.

organisation level:

1.Business unit

2.Team manager

3.Sales manager.


and also i create the three user respectively and assign all user has adminstrator category in user accounts of windows XP.

after create the user and design the manage role to restrict the levels which i have create the dimension.after login which i have to create the user i can see all levels of data.

so pls solution for see data which i have to restrict the dimenssion only..

thanks

kesavan

View 1 Replies View Related

SQL Server2000 And COLUMN DESCRIPTION

Nov 16, 2001

HI

I have a big problem with SQL server2000. I can't get COLUMN DESCRIPTION.
I will print DATADICTIONARY from a DB, I can get all elemnts (table name, columns name, datatype, precision, scale, FK, PK, default value..) I missed only DESCRIPTION. How I can get it????

Medo

View 1 Replies View Related

SQL Server2000 Multiple Instances

Mar 2, 2001

Please Help me on this.
I installed the two instances SQL on one box. ONe is default instance called ACSQL1(actually machine name) and the other one is called ACSQL1/DEVELOPMENT. THrought the my client site of SQL 2000 I can access both instances. When I try to get connection from VB. I can access the default instance but I can not access the second instance. Any ideas about this???
Qun Lu

View 2 Replies View Related

High Availability On MS SQL SERVER2000

Jan 19, 2003

Hi,
I am new in SQL SERVER.I wanted to setup high availability database.It would be great if any one could answers my questions please.
-What are the options availability for HA except clustering?
-How to set up log shipping HA ?
-How to monitor log shipping?
-Is standby DB and log shipping same ?
-Can I setup log shipping without backup/restore method.Like I have to create db1 on server A and create db1 on server B and then configure log shipping?
-Is it necessary to ship log for master database or only user Database?
Thx
-Blace

View 1 Replies View Related

Should I Need I Install SQL Server2000 When Distribute My App

Feb 1, 2004

I want make setup cd for my program and i use visualbasic 6 and SQL Server 2000 .
What i should make and include my setup file to make it work with any one install it in his computer and we assume he dont have SQL Server2000 in his computer .
Please help me on that
Should SQL Server 2000 must alreeady installed on his computer?
If its must be installed,Is there any way to make it easy through my setup file to make it install sql server automatic ?
Can i make my program in visual basic create database and tables and relations and so.
Please help me on that becuase its too Important.
Thanks.

View 1 Replies View Related

Sql Server2000 Analysis Service

Oct 14, 2006

Hi,
I want to install the sql server2000 analysis service.Can you please tell me the website from which I can install that.

View 2 Replies View Related

From Server7/nt4 To New Server2000/windows2000

Aug 14, 2004

Hello,
Can anyone please tell me the best way to upgrade server1 with SERVER7 and OS of NT to a new server2 with SERVER2000 AND WINDOWS 2000 ?
The data in the old server is very important.
Thanks

View 2 Replies View Related

SQL Server2000 DB Restore Problem

Sep 18, 2006

Hi,
I'm wondering if anybody can help me. I have to restore the database from the backup sent by vendor. Backup itself (backup_0906 file) is 60 MB. Below is a statement I run:
RESTORE DATABASE PDMUpload
FROM
DISK = 'e:ftpdirackup_0906'
WITH FILE = 1, NOUNLOAD , STATS = 10, RECOVERY ,
REPLACE ,
MOVE N'PDMUpload_Data' TO N'E:MSSQLDataPDMUpload_Data.MDF',
MOVE N'PDMUpload_Log' TO N'E:MSSQLDataPDMUpload_Log.LDF'

I get the following error messages:

Server: Msg 3257, Level 16, State 1, Procedure RestoreUpload, Line 9
There is insufficient free space on disk volume 'E:' to create the database. The database requires 28181331968 additional free bytes, while only 6759866368 bytes are available.
RESTORE DATABASE is terminating abnormally.

If anybody can explain why DB needs 28 GB???? BTW, there is 6 GB of diskspace available on E: drive.
I appreciate any help.

View 6 Replies View Related

CmdExec Job Step In Sql Server2000

Aug 20, 2007

Thanks for the invitation to post a question, so I will post one.

I need to create a job step that uses cmdExec.

This is the command line I entering:
D:odbcTimeClockUpdatesinReleaseTimeKeepingNo nLogouts.exe

When I run this job the job fails. When I look at the job history, the only information I get is the date and time, user that ran the job and the fact that it failed. I haven't been able to get any CmdExec job to run at all. Can anyone tell me what I'm doing wrong?

Facts.
1. This exact same command is used by my network administrator using windows scheduler on the server. The only reason he wants me to create an sql server job is because it's mostly sql functions.
2. I know the Sql Server agent is running, because I have other jobs that are run.
3. I have verified that I have permission to run the file because I can go to the actual directory and run the exe.
4. Do I need to enclose my command in quotes i.e. “D:odbcTimeClockUpdatesinReleaseTimeKeepingN onLogouts.exe”
5. the path of the file I need to run is the path on the server and not the path on my local machine.

If you need any other information, please let me know
Thanks for you help
GEM

View 7 Replies View Related

Importing Into Sql Server2000 Using DTS From CSV File

Feb 27, 2008

Hello Everybody,
I am importing an csv file into Sql Server straight forward no data cleansing or anything and i noticed everyday it misses the last row in the CSV file.
Has anybody come accross this if so is there anything that i can do to get that row.

ANY HELP ON THIS IS GREATLY APPRECIATED.


Thanks In advance....

View 5 Replies View Related

Bulk Insert Using Vb/sql Server2000

Sep 12, 2006

i have 10 to 15 records in my recordset object. i have to insert all these records in one call to the server instead of calling 15 times.
i am new to sqlserver. please give me a solution with code.

View 10 Replies View Related

How AD Affects SQL Server2000/2005

Dec 5, 2007

hi
at my work place some of the users migrated to another domain even thought with new domain name they can access SQL Server but user who are part of sysadmin(part of some group) on the box unable to execute a job. it means at operating system level newdomainuser credentials are get resolved that's why users are able to access box but why not able to execute jobs. why sysadmin Privilege not get resolved at SQL Server level very confused............

View 7 Replies View Related

Database Sql Server2000 Very Slow

Jul 20, 2005

I have a database that had worked under msde 1.0 until reached the 2GBof dimension and the dB was blocked. To make possible the work i haddeleted old data from some table. The database restart, but theanswers from server become very slow. So i decided to pass to SqlServer 2000 without success. May i perform a check of this database?if is a indexs problem there is a way to rebuild them?Thanks in advanceAndy Wet

View 1 Replies View Related

DBNULL Error - SQL Server2000/ASP.NET

Jul 20, 2005

Dear GroupI'm having a very weird problem. Any hints are greatly appreciated.I'm returning two values from a MS SQL Server 2000 stored procedure to myASP.NET Webapplication and store them in sessions.Like This:prm4 = cmd1.CreateParameterWith prm4..ParameterName = "@Sec_ProgUser_Gen"..SqlDbType = SqlDbType.VarChar..Size = 10..Direction = ParameterDirection.OutputEnd Withprm5 = cmd1.CreateParameterWith prm5..ParameterName = "@Sec_ProgUser_Key"..SqlDbType = SqlDbType.VarChar..Size = 10..Direction = ParameterDirection.OutputEnd With....cmd1.ExecuteNonQuery()....Session("Sec_ProgUser_Gen") = prm4.ValueSession("Sec_ProgUser_Key") = prm5.ValueBoth output parameters are declared as varchar(10) within the storedprocedure. If I run the stored procedure in SQL Analyzer, I'm getting astring value for each of them. E.g. @Sec_ProgUser_Gen is "1110011",@Sec_ProgUser_Key = "1100".Now the strange thing happens if I try to run the following code:Sub MyTest()Dim MyString1 As StringDim MyString2 As StringMyString1 = CStr(Session("Sec_ProgUser_Key"))....MyString2 = CStr(Session("Sec_ProgUser_Gen"))End SubIt fails in line 'MyString2 = CStr(Session("Sec_ProgUser_Gen"))' with Castfrom type 'DBNull' to type 'String' is not valid.I don't understand this. They are both the same, the only difference is thelength of the string. Help!Additional Information:The values for @Sec_ProgUser_XXX are created in the stored procedure with astatement like this:SET @Sec_ProgUser_Key = (SELECT Convert(varchar(1),Key_CanCreateKey) +Convert(varchar(1),Key_CanCreateTransaction) +Convert(varchar(1),Key_CanView) + Convert(varchar(1),Key_CanDelete) FROMi2b_proguser_securityprofile WHERE SecurityProfileID = @SecurityProfileID)The datatype of the source columns used to be bit then changed them toInteger as I thought this might cause the problem. (Although it shouldn't asthe values get converted to varchar without a problem in the storedprocedure. No fields contain NULL values, only 1 or 0.

View 1 Replies View Related

Email Alert In SQL Server2000

Sep 17, 2007

can somebody help me to setup email alerts in SQL Server 2000 standard edition whenever, backup is successful OR failed to complete.

Thanks,

View 1 Replies View Related

How Can I Configure Sql Server2000 With Vb.net2003

Sep 16, 2006



Hi



I got an exe file of an application with program debug database.

Once i am running that program it is giving an error.

Can anyone suggest me how to configure SQL server2000 database with this application.

I have installed client tool of SQL server2000 on my system.

I am very new in MS platform.

................................................................................................................................

The error is like this

it is showing this error

System.Data.Sql.Client.qlException: SQL server does not exist or access denied.
at DataAccess.DataAccess.ExecuteInsertUpdateDeleteQuery(String prsConnString, String StoredProcName,sqlParameter[]parameterLost)

Thanks



View 1 Replies View Related

How To Write A Stored Procedure In SQL Server2000?

Jan 28, 2008

 
Hi all,
 
  I want to write a stored procedure for the following,
  The table have the following field,
  CategoryID, CategoryName,                    Parent_categoryID
  123             Kids Dresses                        0
  321             Kids Boys                            123
  322             Kids Baby                            123
  401             Kids Boys school Uniform     321
  501            Kids Boys Formals                321
  541            Kids Baby school Uniform      322
  542            Kids Baby Formals                322
  601            Household Textile                  0
  602           Bathrobe                               601
  603           Carpet                                  601
  604           Table Cloth                           601
 
 From the above example the categoryID acts as a parent_categoryID for some products,
 when i pass a categoryID the stored procedure should return all the categoryID which are subcategory to given categoryID,
 subcategory may contain some subcategory, so when i give a categoryID it should return all the subcategoryID.
 For example when i pass categoryID as 123 it should return the following subcategoryIDs
 321,322,401,501,541,542 because these are all subcategory of categoryID 123.
 How to write stored procedure for this?
 
Thanks!

View 6 Replies View Related







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