SQL Server Forums
Profile | Register | Active Topics | Members | Search | Forum FAQ
 
Register Now and get your question answered!
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 SQL Server 2012 Forums
 Transact-SQL (2012)
 Help
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic  

eltonyau
Starting Member

Canada
1 Posts

Posted - 03/29/2014 :  05:43:33  Show Profile  Reply with Quote
Can anyone tell me what this code means? super new to sql and i dont know how to decipher this code


CREATE proc [dbo].[uspStore]
@uType varchar(50)=null,
@Officeid bigint=null,
@SupplyId bigint=null,
@DF2 bigint=null,
@df8 bigint=null,
@ItemID varchar(1000)=null,
@SuppliedValue varchar(1000)=null,
@ReceivedQty varchar(1000)=null,
@Reason varchar(1000)=null,
@Message varchar(2000)=null,
@DF4 varchar(50) =Null,
@DF5 varchar(50) =Null,
@PgName varchar(100)=Null,
@ClsName varchar(100)=Null,
@FnName varchar(100)=Null,
@IssueId bigint=null,
@AvailablebalanceInStock varchar(200)=null,
@Qty varchar(200)=null,
@ReturnId bigint=null,
@ReturnExchangeId bigint=null,
@ReturnedQty varchar(200)=null,
@SupplierId bigint=null,
@DistributorId bigint=null,
@FinYear varchar(200)=null,
@TenderId bigint =null,
@IsApproved smallint=null,
@RateId varchar(200)=null,
@TenderIdStr varchar(100)=null,
@AgreementId varchar(100)=null,
@FinancialYear varchar(10)=null,
@ConsigneeId bigint=null,
@OrderId bigint=null,
@StrTenderItemRateId varchar(100)=null,
@strQtyAnnual varchar(100)=null,
@strQtyOrder varchar(100)=null,
@strLots varchar(100)=null ,
@SupplierIdStr varchar(100)=null,
@SupplyType varchar(10)=null,
@ChalanNo varchar(500)=null,
@BillDate varchar(50)=null,
@BillID bigint=null
as
begin

if @uType='ShowWordReport'
Begin

Select T287001 as ID,T287003 as Name,T287002 as Type from T287 where T287DF7=1 and T287005=@Officeid
End

else if @uType='bindSupplyDetails'

Begin
select T234002 as ItemCode,T234003 as ItemName,T234010 as StrengthSpecific,T234013 as Form,T234004 as unit,T286004 as batchno,CONVERT(varchar,T286005,105) as mfgdate,
CONVERT(varchar, T286006,105) as expirydate,T286010 as brandname,T286007 qtysuppliedunit,(T286009*T286007) as Amt,T286001 as SupplyitemDetail from T234 inner join T286 on T286003= T234001
and T286002=@SupplyId inner join T285 on T285001=T286002 where ISNULL(T285009,0)=@IsApproved

end

What does the T_ _ _ _ _ _ mean?

khtan
In (Som, Ni, Yak)

Singapore
17658 Posts

Posted - 03/29/2014 :  10:00:20  Show Profile  Reply with Quote
quote:
What does the T_ _ _ _ _ _ mean

that is the column name from table T287 or T234 or T286

you can find out more about that table using sp_help. Example

exec sp_help T287



KH
Time is always against us

Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
 Printer Friendly
Jump To:
SQL Server Forums © 2000-2009 SQLTeam Publishing, LLC Go To Top Of Page
This page was generated in 0.12 seconds. Powered By: Snitz Forums 2000