Error in query: [Microsoft][SQL Server Native Client 10.0][SQL Server]Must specify table to select from. '' (SWEI)
Hi All
below query giving me error in query generator but working well in Sql server.
error: [Microsoft][SQL Server Native Client 10.0][SQL Server]Must specify table to select from. '' (SWEI)
Select
T1.U_grp01 As 'BA',T3.DocDate As 'Posting Date',Month(T3.DocDate) As 'PostMonth',Year(T3.DocDate) As 'PostYear',
'AR Invoice' As 'Type',T3.DocNum As 'Doc No',T3.CardCode As 'Cust. Code',T3.CardName As 'Cust. Name',T5.SlpName As 'Sale Emp. Name',
T4.IndustryC As 'Channel Type',T6.CityB As 'BillToCity',T7.Name As 'BillToState',T6.CityS As 'ShipToCity',T8.Name As 'ShipToState',
T4.U_Une_Zone As 'Zone',
T2.ItmsGrpNam As 'L1',T0.LineNum As 'Row No',T0.ItemCode As 'ItemCode',T0.Dscription As 'Item Name',t0.whscode,
T0.Quantity As 'Quantity',T0.StockPrice As 'COGS Price',IsNull(Sum(T0.Quantity * T0.StockPrice),0) As 'COGS Value',T0.VatSum As 'Tax Amount',
IsNull((Case When T3.DocType='I' Then (Case When T0.Currency = 'INR' Then T0.PriceBefDi Else (T0.PriceBefDi * T0.Rate) End) Else T0.Price End) ,0) As 'Sales Price',
IsNull((Case When T3.DocType='I' Then (Case When T0.Currency = 'INR' Then T0.INMPrice Else (T0.INMPrice * T0.Rate) End) Else T0.Price End) ,0) As 'Sales Price',
IsNull((Case When T3.DocType='I' Then (Case When T0.Currency = 'INR' Then Sum(T0.Quantity * T0.INMPrice) Else Sum(T0.Quantity * T0.INMPrice * T0.Rate) End) Else T0.LineTotal End) ,0) As 'Sales Value',t9.linetotal as 'Freight',
T3.DocType As 'DocType',
(SELECT DISTINCT ISNULL (SUM(INV4.TaxSum),0)
FROM INV4
WHERE INV4.StaType = -90
AND INV4.DocEntry = T3.DocEntry
AND INV4.LineNum = T0.LineNum) AS 'BED',
(SELECT DISTINCT ISNULL (SUM(INV4.TaxSum),0)
FROM INV4
WHERE INV4.StaType = -60
AND INV4.DocEntry = T3.DocEntry
AND INV4.LineNum = T0.LineNum) AS 'Cess',
(SELECT DISTINCT ISNULL (SUM(INV4.TaxSum),0)
FROM INV4
WHERE INV4.StaType = 9
AND INV4.DocEntry = T3.DocEntry
AND INV4.LineNum = T0.LineNum) AS 'HeCess',
(SELECT DISTINCT ISNULL (SUM(INV4.TaxSum),0)
FROM INV4
WHERE (INV4.StaType = 1 or inv4.staType = 8)
AND INV4.DocEntry = T3.DocEntry
AND INV4.LineNum = T0.LineNum) AS 'VAT',
(SELECT DISTINCT ISNULL (SUM(INV4.TaxSum),0)
FROM INV4
WHERE INV4.StaType = 8
AND INV4.DocEntry = T3.DocEntry
AND INV4.LineNum = T0.LineNum) AS 'CST'
From INV1 T0
Left Join OITM T1 On T1.ItemCode=T0.ItemCode
Left Join OITB T2 On T2.ItmsGrpCod=T1.ItmsGrpCod
Left Join OINV T3 On T3.DocEntry=T0.DocEntry
Left Join OCRD T4 On T4.CardCode=T3.CardCode
Left Join OSLP T5 On T5.SlpCode=T4.SlpCode
Left Join INV12 T6 On T6.DocEntry=T0.DocEntry
Left Join OCST T7 On T7.Code=T6.StateB and T7.Country='IN'
Left Join OCST T8 On T8.Code=T6.StateS and T8.Country='IN'
left join inv3 t9 on t9.docentry = t3.docentry
WHERE T3.[DocDate] >= [%0] and T3.[DocDate] <= [%1] and t3.U_UNE_GCAT = '2'
Group By T1.U_grp01,T3.DocEntry,T3.DocNum,T3.DocDate,T0.LineNum,T3.CardCode,T3.CardName,T5.SlpName,T4.IndustryC,T4.U_Une_Zone,
T6.CityB,T7.Name,T6.CityS,T8.Name,T0.VatSum,T0.Currency,T0.Rate,T3.DocType,T0.Price,T0.LineTotal,
T2.ItmsGrpNam,T0.ItemCode,T0.Dscription,T0.StockPrice,T0.INMPrice,T0.PriceBefDi,T0.Quantity,t9.linetotal,t0.WhsCode
Union All
Select
T1.U_grp01 As 'BA',T3.DocDate As 'Posting Date',Month(T3.DocDate) As 'PostMonth',Year(T3.DocDate) As 'PostYear',
'AR Invoice' As 'Type',T3.DocNum As 'Doc No',T3.CardCode As 'Cust. Code',T3.CardName As 'Cust. Name',T5.SlpName As 'Sale Emp. Name',
T4.IndustryC As 'Channel Type',T6.CityB As 'BillToCity',T7.Name As 'BillToState',T6.CityS As 'ShipToCity',T8.Name As 'ShipToState',
T4.U_Une_Zone As 'Zone',
T2.ItmsGrpNam As 'L1',T0.LineNum As 'Row No',T0.ItemCode As 'ItemCode',T0.Dscription As 'Item Name',t0.whscode,
T0.Quantity As 'Quantity',T0.StockPrice As 'COGS Price',IsNull(Sum(T0.Quantity * T0.StockPrice),0) As 'COGS Value',T0.VatSum As 'Tax Amount',
IsNull((Case When T3.DocType='I' Then (Case When T0.Currency = 'INR' Then T0.PriceBefDi Else (T0.PriceBefDi * T0.Rate) End) Else T0.Price End) ,0) As 'Sales Price',
IsNull((Case When T3.DocType='I' Then (Case When T0.Currency = 'INR' Then T0.INMPrice Else (T0.INMPrice * T0.Rate) End) Else T0.Price End) ,0) As 'Sales Price',
IsNull((Case When T3.DocType='I' Then (Case When T0.Currency = 'INR' Then Sum(T0.Quantity * T0.INMPrice) Else Sum(T0.Quantity * T0.INMPrice * T0.Rate) End) Else T0.LineTotal End) ,0) As 'Sales Value',t9.linetotal as 'Freight',
T3.DocType As 'DocType',
(SELECT DISTINCT ISNULL (SUM(rin4.TaxSum),0)
FROM rin4
WHERE rin4.StaType = -90
AND rin4.DocEntry = T3.DocEntry
AND rin4.LineNum = T0.LineNum) AS 'BED',
(SELECT DISTINCT ISNULL (SUM(rin4.TaxSum),0)
FROM rin4
WHERE rin4.StaType = -60
AND rin4.DocEntry = T3.DocEntry
AND rin4.LineNum = T0.LineNum) AS 'Cess',
(SELECT DISTINCT ISNULL (SUM(rin4.TaxSum),0)
FROM rin4
WHERE rin4.StaType = 9
AND rin4.DocEntry = T3.DocEntry
AND rin4.LineNum = T0.LineNum) AS 'HeCess',
(SELECT DISTINCT ISNULL (SUM(rin4.TaxSum),0)
FROM rin4
WHERE (rin4.StaType = 1 or rin4.staType = 8)
AND rin4.DocEntry = T3.DocEntry
AND rin4.LineNum = T0.LineNum) AS 'VAT',
(SELECT DISTINCT ISNULL (SUM(rin4.TaxSum),0)
FROM rin4
WHERE rin4.StaType = 8
AND rin4.DocEntry = T3.DocEntry
AND rin4.LineNum = T0.LineNum) AS 'CST'
From rin1 T0
Left Join OITM T1 On T1.ItemCode=T0.ItemCode
Left Join OITB T2 On T2.ItmsGrpCod=T1.ItmsGrpCod
Left Join Orin T3 On T3.DocEntry=T0.DocEntry
Left Join OCRD T4 On T4.CardCode=T3.CardCode
Left Join OSLP T5 On T5.SlpCode=T4.SlpCode
Left Join rin12 T6 On T6.DocEntry=T0.DocEntry
Left Join OCST T7 On T7.Code=T6.StateB and T7.Country='IN'
Left Join OCST T8 On T8.Code=T6.StateS and T8.Country='IN'
left join rin3 t9 on t9.docentry = t3.docentry
WHERE T3.[DocDate] >= [%0] and T3.[DocDate] <= [%1] and t3.U_UNE_GCAT = '2'
Group By T1.U_grp01,T3.DocEntry,T3.DocNum,T3.DocDate,T0.LineNum,T3.CardCode,T3.CardName,T5.SlpName,T4.IndustryC,T4.U_Une_Zone,
T6.CityB,T7.Name,T6.CityS,T8.Name,T0.VatSum,T0.Currency,T0.Rate,T3.DocType,T0.Price,T0.LineTotal,
T2.ItmsGrpNam,T0.ItemCode,T0.Dscription,T0.StockPrice,T0.INMPrice,T0.PriceBefDi,T0.Quantity,t9.linetotal,t0.WhsCode
Thanks in Advance
Hi deepak..
try this
/* SELECT FROM OSRT P1 */
DECLARE @FROM AS DATE
/* WHERE */
SET @FROM = /* P1.FromDate */ '[%1]'
/* SELECT FROM OSRT P2 */
DECLARE @TO AS DATE
/* WHERE */
SET @TO = /* P2.ToDate */ '[%2]';
SELECT T1.U_grp01 AS 'BA',
T3.DocDate AS 'Posting Date',
MONTH(T3.DocDate) AS 'PostMonth',
YEAR(T3.DocDate) AS 'PostYear',
'AR Invoice' AS 'Type',
T3.DocNum AS 'Doc No',
T3.CardCode AS 'Cust. Code',
T3.CardName AS 'Cust. Name',
T5.SlpName AS 'Sale Emp. Name',
T4.IndustryC AS 'Channel Type',
T6.CityB AS 'BillToCity',
T7.Name AS 'BillToState',
T6.CityS AS 'ShipToCity',
T8.Name AS 'ShipToState',
T4.U_Une_Zone AS 'Zone',
T2.ItmsGrpNam AS 'L1',
T0.LineNum AS 'Row No',
T0.ItemCode AS 'ItemCode',
T0.Dscription AS 'Item Name',
t0.whscode,
T0.Quantity AS 'Quantity',
T0.StockPrice AS 'COGS Price',
ISNULL(SUM(T0.Quantity * T0.StockPrice), 0) AS 'COGS Value',
T0.VatSum AS 'Tax Amount',
ISNULL(
CASE
WHEN T3.DocType = 'I' THEN (
CASE
WHEN T0.Currency = 'INR' THEN T0.PriceBefDi
ELSE (T0.PriceBefDi * T0.Rate)
END
ELSE T0.Price
END
0
) AS 'Sales Price',
ISNULL(
CASE
WHEN T3.DocType = 'I' THEN (
CASE
WHEN T0.Currency = 'INR' THEN T0.INMPrice
ELSE (T0.INMPrice * T0.Rate)
END
ELSE T0.Price
END
0
) AS 'Sales Price',
ISNULL(
CASE
WHEN T3.DocType = 'I' THEN (
CASE
WHEN T0.Currency = 'INR' THEN SUM(T0.Quantity * T0.INMPrice)
ELSE SUM(T0.Quantity * T0.INMPrice * T0.Rate)
END
ELSE T0.LineTotal
END
0
) AS 'Sales Value',
t9.linetotal AS 'Freight',
T3.DocType AS 'DocType',
SELECT DISTINCT ISNULL(SUM(INV4.TaxSum), 0)
FROM INV4
WHERE INV4.StaType = -90
AND INV4.DocEntry = T3.DocEntry
AND INV4.LineNum = T0.LineNum
) AS 'BED',
SELECT DISTINCT ISNULL(SUM(INV4.TaxSum), 0)
FROM INV4
WHERE INV4.StaType = -60
AND INV4.DocEntry = T3.DocEntry
AND INV4.LineNum = T0.LineNum
) AS 'Cess',
SELECT DISTINCT ISNULL(SUM(INV4.TaxSum), 0)
FROM INV4
WHERE INV4.StaType = 9
AND INV4.DocEntry = T3.DocEntry
AND INV4.LineNum = T0.LineNum
) AS 'HeCess',
SELECT DISTINCT ISNULL(SUM(INV4.TaxSum), 0)
FROM INV4
WHERE (INV4.StaType = 1 OR inv4.staType = 8)
AND INV4.DocEntry = T3.DocEntry
AND INV4.LineNum = T0.LineNum
) AS 'VAT',
SELECT DISTINCT ISNULL(SUM(INV4.TaxSum), 0)
FROM INV4
WHERE INV4.StaType = 8
AND INV4.DocEntry = T3.DocEntry
AND INV4.LineNum = T0.LineNum
) AS 'CST'
FROM INV1 T0
LEFT JOIN OITM T1
ON T1.ItemCode = T0.ItemCode
LEFT JOIN OITB T2
ON T2.ItmsGrpCod = T1.ItmsGrpCod
LEFT JOIN OINV T3
ON T3.DocEntry = T0.DocEntry
LEFT JOIN OCRD T4
ON T4.CardCode = T3.CardCode
LEFT JOIN OSLP T5
ON T5.SlpCode = T4.SlpCode
LEFT JOIN INV12 T6
ON T6.DocEntry = T0.DocEntry
LEFT JOIN OCST T7
ON T7.Code = T6.StateB
AND T7.Country = 'IN'
LEFT JOIN OCST T8
ON T8.Code = T6.StateS
AND T8.Country = 'IN'
LEFT JOIN inv3 t9
ON t9.docentry = t3.docentry
WHERE T3.[DocDate] >= @FROM
AND T3.[DocDate] <= @TO
AND t3.U_UNE_GCAT = '2'
GROUP BY
T1.U_grp01,
T3.DocEntry,
T3.DocNum,
T3.DocDate,
T0.LineNum,
T3.CardCode,
T3.CardName,
T5.SlpName,
T4.IndustryC,
T4.U_Une_Zone,
T6.CityB,
T7.Name,
T6.CityS,
T8.Name,
T0.VatSum,
T0.Currency,
T0.Rate,
T3.DocType,
T0.Price,
T0.LineTotal,
T2.ItmsGrpNam,
T0.ItemCode,
T0.Dscription,
T0.StockPrice,
T0.INMPrice,
T0.PriceBefDi,
T0.Quantity,
t9.linetotal,
t0.WhsCode
UNION ALL
SELECT T1.U_grp01 AS 'BA',
T3.DocDate AS 'Posting Date',
MONTH(T3.DocDate) AS 'PostMonth',
YEAR(T3.DocDate) AS 'PostYear',
'AR Invoice' AS 'Type',
T3.DocNum AS 'Doc No',
T3.CardCode AS 'Cust. Code',
T3.CardName AS 'Cust. Name',
T5.SlpName AS 'Sale Emp. Name',
T4.IndustryC AS 'Channel Type',
T6.CityB AS 'BillToCity',
T7.Name AS 'BillToState',
T6.CityS AS 'ShipToCity',
T8.Name AS 'ShipToState',
T4.U_Une_Zone AS 'Zone',
T2.ItmsGrpNam AS 'L1',
T0.LineNum AS 'Row No',
T0.ItemCode AS 'ItemCode',
T0.Dscription AS 'Item Name',
t0.whscode,
T0.Quantity AS 'Quantity',
T0.StockPrice AS 'COGS Price',
ISNULL(SUM(T0.Quantity * T0.StockPrice), 0) AS 'COGS Value',
T0.VatSum AS 'Tax Amount',
ISNULL(
CASE
WHEN T3.DocType = 'I' THEN (
CASE
WHEN T0.Currency = 'INR' THEN T0.PriceBefDi
ELSE (T0.PriceBefDi * T0.Rate)
END
ELSE T0.Price
END
0
) AS 'Sales Price',
ISNULL(
CASE
WHEN T3.DocType = 'I' THEN (
CASE
WHEN T0.Currency = 'INR' THEN T0.INMPrice
ELSE (T0.INMPrice * T0.Rate)
END
ELSE T0.Price
END
0
) AS 'Sales Price',
ISNULL(
CASE
WHEN T3.DocType = 'I' THEN (
CASE
WHEN T0.Currency = 'INR' THEN SUM(T0.Quantity * T0.INMPrice)
ELSE SUM(T0.Quantity * T0.INMPrice * T0.Rate)
END
ELSE T0.LineTotal
END
0
) AS 'Sales Value',
t9.linetotal AS 'Freight',
T3.DocType AS 'DocType',
SELECT DISTINCT ISNULL(SUM(rin4.TaxSum), 0)
FROM rin4
WHERE rin4.StaType = -90
AND rin4.DocEntry = T3.DocEntry
AND rin4.LineNum = T0.LineNum
) AS 'BED',
SELECT DISTINCT ISNULL(SUM(rin4.TaxSum), 0)
FROM rin4
WHERE rin4.StaType = -60
AND rin4.DocEntry = T3.DocEntry
AND rin4.LineNum = T0.LineNum
) AS 'Cess',
SELECT DISTINCT ISNULL(SUM(rin4.TaxSum), 0)
FROM rin4
WHERE rin4.StaType = 9
AND rin4.DocEntry = T3.DocEntry
AND rin4.LineNum = T0.LineNum
) AS 'HeCess',
SELECT DISTINCT ISNULL(SUM(rin4.TaxSum), 0)
FROM rin4
WHERE (rin4.StaType = 1 OR rin4.staType = 8)
AND rin4.DocEntry = T3.DocEntry
AND rin4.LineNum = T0.LineNum
) AS 'VAT',
SELECT DISTINCT ISNULL(SUM(rin4.TaxSum), 0)
FROM rin4
WHERE rin4.StaType = 8
AND rin4.DocEntry = T3.DocEntry
AND rin4.LineNum = T0.LineNum
) AS 'CST'
FROM rin1 T0
LEFT JOIN OITM T1
ON T1.ItemCode = T0.ItemCode
LEFT JOIN OITB T2
ON T2.ItmsGrpCod = T1.ItmsGrpCod
LEFT JOIN [dbo].[Orin] T3
ON T3.DocEntry = T0.DocEntry
LEFT JOIN OCRD T4
ON T4.CardCode = T3.CardCode
LEFT JOIN OSLP T5
ON T5.SlpCode = T4.SlpCode
LEFT JOIN rin12 T6
ON T6.DocEntry = T0.DocEntry
LEFT JOIN OCST T7
ON T7.Code = T6.StateB
AND T7.Country = 'IN'
LEFT JOIN OCST T8
ON T8.Code = T6.StateS
AND T8.Country = 'IN'
LEFT JOIN rin3 t9
ON t9.docentry = t3.docentry
WHERE T3.[DocDate] >= @FROM
AND T3.[DocDate] <= @TO
AND t3.U_UNE_GCAT = '2'
GROUP BY
T1.U_grp01,
T3.DocEntry,
T3.DocNum,
T3.DocDate,
T0.LineNum,
T3.CardCode,
T3.CardName,
T5.SlpName,
T4.IndustryC,
T4.U_Une_Zone,
T6.CityB,
T7.Name,
T6.CityS,
T8.Name,
T0.VatSum,
T0.Currency,
T0.Rate,
T3.DocType,
T0.Price,
T0.LineTotal,
T2.ItmsGrpNam,
T0.ItemCode,
T0.Dscription,
T0.StockPrice,
T0.INMPrice,
T0.PriceBefDi,
T0.Quantity,
t9.linetotal,
t0.WhsCode
rgds
Kennedy
Similar Messages
-
Error while executing SQL query -' Must Specify Table to select from'
Hi all,
While executing query using query generator
it shows error message
[Microsoft][SQL Native Client][SQL Server]Must specify table to select from.
2). [Microsoft][SQL Nativ
SELECT T1.ItemCode, T1.Dscription AS 'Item Description', T1.Quantity, T1.Price, T1.LineTotal,
(Select SUM(T2.TaxSum) From PCH4 T2 Where T0.DocEntry=T2.DocEntry AND T2.staType=-90 AND T1.LineNum=T2.LineNum) as 'BEDAmt',
(Select SUM(T2.TaxSum) From PCH4 T2 Where T0.DocEntry=T2.DocEntry AND T2.staType=-60 AND T1.LineNum=T2.LineNum) as 'ECSAmt',
(Select SUM(T2.TaxSum) From PCH4 T2 Where T0.DocEntry=T2.DocEntry AND T2.staType=7 AND T1.LineNum=T2.LineNum) as 'HECSAmt',
(Select SUM(T2.TaxSum) From PCH4 T2 Where T0.DocEntry=T2.DocEntry AND T2.staType=1 AND T1.LineNum=T2.LineNum) as 'VATAmt',
(Select SUM(T2.TaxSum) From PCH4 T2 Where T0.DocEntry=T2.DocEntry AND T2.staType=4 AND T1.LineNum=T2.LineNum) as 'CSTAmt'
FROM dbo.[OPCH] T0 INNER JOIN PCH1 T1 ON T0.DocEntry = T1.DocEntry INNER JOIN PCH4 T2 ON T2.DocEntry=T0.DocEntry
WHERE T0.DocDate >='[%0]' AND T0.DocDate <='[%1]' AND T0.DocType = 'I'
GROUP BY T1.ItemCode,T1.Dscription,T1.Quantity, T1.Price, T1.LineTotal,T0.DocEntry,T1.DocEntry,T1.LineNum,T2.LineNum
It's executing fine in MS SQL Server Studio Management.
Please give y'r ideas to solve the problem.
Jeyakanthantry this, it works fine in my B1:
SELECT T1.ItemCode, T1.Dscription AS 'Item Description', T1.Quantity, T1.Price, T1.LineTotal,
(Select SUM(T2.TaxSum) From PCH4 T2 Where T0.DocEntry=T2.DocEntry AND T2.staType=-90 AND T1.LineNum=T2.LineNum) as 'BEDAmt',
(Select SUM(T2.TaxSum) From PCH4 T2 Where T0.DocEntry=T2.DocEntry AND T2.staType=-60 AND T1.LineNum=T2.LineNum) as 'ECSAmt',
(Select SUM(T2.TaxSum) From PCH4 T2 Where T0.DocEntry=T2.DocEntry AND T2.staType=7 AND T1.LineNum=T2.LineNum) as 'HECSAmt',
(Select SUM(T2.TaxSum) From PCH4 T2 Where T0.DocEntry=T2.DocEntry AND T2.staType=1 AND T1.LineNum=T2.LineNum) as 'VATAmt',
(Select SUM(T2.TaxSum) From PCH4 T2 Where T0.DocEntry=T2.DocEntry AND T2.staType=4 AND T1.LineNum=T2.LineNum) as 'CSTAmt'
FROM dbo.OPCH T0 INNER JOIN PCH1 T1 ON T0.DocEntry = T1.DocEntry INNER JOIN PCH4 T2 ON T2.DocEntry=T0.DocEntry
WHERE T0.DocDate >='[%0]' AND T0.DocDate <='[%1]' AND T0.DocType = 'I'
GROUP BY T1.ItemCode,T1.Dscription,T1.Quantity, T1.Price, T1.LineTotal,T0.DocEntry,T1.DocEntry,T1.LineNum,T2.LineNum
B1 don't like brackets!
Regards -
SAP query error - 1). [Microsoft][SQL Server Native Client 10.0][SQL Server]Conversion failed when converting date and/or time from character string. 'Received Alerts' (OAIB)
SELECT
CASE WHEN T0.DocStatus = 'O' THEN 'OPEN'
WHEN T0.DocStatus = 'C' THEN 'CLOSED' END AS 'Document Status',
T0.DocDate AS 'Posting Date',
T0.DocNum AS 'Doc.No',
T0.NumAtCard,
T0.TransId AS 'Trans. No.',
T0.Comments AS 'Remarks',
T0.CardCode AS 'Offset Acct',
T0.CardName AS 'Offset Acct Name',
sum(T0.DocTotal) + (T0.WTSum) as 'DocTotal',
T3.DueDate AS 'Cheque Date',
T3.CheckSum AS 'Amount'
FROM ODPO AS T0 LEFT OUTER JOIN
VPM2 AS T1 ON T0.ObjType = T1.InvType AND T0.DocEntry = T1.DocEntry LEFT OUTER JOIN
OVPM AS T2 ON T2.DocEntry = T1.DocNum LEFT OUTER JOIN
VPM1 AS T3 ON T2.DocEntry = T3.DocNum
where T0.DocDate>='[%0]' and T0.DocDate<='[%1]'Hi,
Try this:
SELECT
CASE WHEN T0.DocStatus = 'O' THEN 'OPEN'
WHEN T0.DocStatus = 'C' THEN 'CLOSED' END AS 'Document Status',
T0.DocDate AS 'Posting Date',
T0.DocNum AS 'Doc.No',
T0.NumAtCard,
T0.TransId AS 'Trans. No.',
T0.Comments AS 'Remarks',
T0.CardCode AS 'Offset Acct',
T0.CardName AS 'Offset Acct Name',
sum(T0.DocTotal) + (T0.WTSum) as 'DocTotal',
T3.DueDate AS 'Cheque Date',
T3.CheckSum AS 'Amount'
FROM ODPO T0 LEFT OUTER JOIN
VPM2 T1 ON T0.ObjType = T1.InvType AND T0.DocEntry = T1.DocEntry
LEFT OUTER JOIN
OVPM T2 ON T2.DocEntry = T1.DocNum LEFT OUTER JOIN
VPM1 T3 ON T2.DocEntry = T3.DocNum
where T0.DocDate >= '[%0]' and T0.DocDate <='[%1]'
group by T0.DocStatus,T0.DocDate ,
T0.DocNum ,
T0.NumAtCard,
T0.TransId ,
T0.Comments ,
T0.CardCode,
T0.CardName ,
T0.WTSum ,
T3.DueDate ,
T3.CheckSum
Thanks & Regards,
Nagarajan -
I am getting following error in each module of SAP B1 9.0 and hence unable to use SAP b'coz I can't add or change any document b'coz of this error.
Error : [Microsoft][SQL Server Native Client 10.0][SQL Server]Invalid object name 'UNKNOW ERROR'. (CINF)
please help me to resolve this issue.I am getting following error in each module of SAP B1 9.0 and hence unable to use SAP b'coz I can't add or change any document b'coz of this error.
Error : [Microsoft][SQL Server Native Client 10.0][SQL Server]Invalid object name 'UNKNOW ERROR'. (CINF)
please help me to resolve this issue. -
Dear Experts,
i am getting the below error when i was giving * (Star) to view all the items in DB
[Microsoft][SQL Server Native Client 11.0][SQL Server]The text, ntext, and image data types cannot be compared or sorted, except when using IS NULL or LIKE operator. 'Items' (OITM) (OITM)
As i was searching individually it is working fine
can any one help me how to find this..
Regards,
Meghanath.SDear Nithi Anandham,
i am not having any query while finding all the items in item master data i am giving find mode and in item code i was trying to type *(Star) and enter while typing enter the above issue i was facing..
Regards,
Meghanath -
*** [23000][2627][Microsoft][SQL Server Native Client 11.0][SQL Server]Violation of UNIQUE KEY constraint 'ClientPushMachine_G_AK'. Cannot insert duplicate key in object 'dbo.ClientPushMachine_G'. The duplicate key value is (16777412). : sp_CP_CheckNewAssignedMachine
CCCRT::RunSQLStoredProc - Failed to execute SQL cmd exec [sp_CP_CheckNewAssignedMachine] N'xxx', 1
CCRQueueRequest::GetRequestFromQueue - Failed to execute SQL cmd sp_CP_CheckNewAssignedMachine
I get the above issue and the one below at a client site; the error started with the error below then changed to the one reported above and back to the one below. Everything is working as it should but the issues
started when one of the admins at the data-centre incorrectly applied a gpo which affected a number of service accounts (sccm inclusive) and they expired....hence reporting in sccm got broke as well as this error in the ccm.log file appeared.
Remote client install still works but I believe this error affects new client discovered by sccm, so in other words devices discovered by sccm do not get the client installed automatically....but if all access and permissions are in place...pushing out the
client to the new discovered system works, it just not done automatically, which kinda defeats one the reasons for using sccm.
I have searched the breadth of the tinternet and I can only find two technet reference to the same error - one says to edit the stored procedure on the sql server which I don't think should be done... Like Jason said and I concur....its bad joo joos.
The second suggestion, said you should select all the options in the Client Push Installation properties, I have tried this but hasn't solved the problem.
I am planning to upgrade the site to the R2 CU3 before the end of the year but I would like to resolve this error before the upgrade.
The site is currently sccm 2012 sp1
Any idea?> Resolution? sil vous plait!
MerciHi ,
Please back up the database of the SCCM site. Then run the following query against the Site DB and see how it goes.
DELETE FROM System_SMS_Resident_ARR
WHERE ItemKey IN (
SELECT ItemKey FROM vSystem_SMS_Resident_ARR
GROUP BY ItemKey
HAVING COUNT(ItemKey) > 1
Please remember to click “Mark as Answer” on the post that helps you, and to click “Unmark as Answer” if a marked post does not actually answer your question. This can be beneficial to other community members reading the thread. -
Cannot install SQL Server Native Client 2012 on Windows Server 2008 Data Center
Is it possible to install SQL Server Native Client 11.0 (SQL Server 2012) on Windows Server 2008 Datacenter?
I tried to install it, but I get this error message:
"Installation of this product failed because it is not supported on this operating system. For information on supported configurations, see the product documentation."
Based on this article (http://msdn.microsoft.com/en-us/library/cc280356.aspx), I see one of the supported operating system is Windows Server 2008.Hello,
Can you try to download and install Windows Server 2008 Service Pack 2 from the following link, and then reinstall the SQL Server Native Client 11.0 again?
http://www.microsoft.com/en-in/download/details.aspx?id=16468
Microsoft SQL Server 2012 Native Client is included in the SQL Server 2012 Feature Pack. Based on the requirement of
the download page , you should apply SP2 for Windows Server 2008.
Regards,
Fanny Liu
Fanny Liu
TechNet Community Support -
Dear Experts
I am getting the following error message while adding item in Item Master data. I have modified the following SBO_SP_transactionNotification in SQL server after that could not able to add the item
ALTER proc [dbo].[SBO_SP_TransactionNotification]
@object_type nvarchar(20), -- SBO Object Type
@transaction_type nchar(1), -- [A]dd, [U]pdate, [D]elete, [C]ancel, C[L]ose
@num_of_cols_in_key int,
@list_of_key_cols_tab_del nvarchar(255),
@list_of_cols_val_tab_del nvarchar(255)
AS
begin
-- Return values
declare @error int -- Result (0 for no error)
declare @error_message nvarchar (200) -- Error string to be displayed
select @error = 0
select @error_message = N'Ok'
-- IF @OBJECT_TYPE = '59' AND (@TRANSACTION_TYPE = 'A' or @TRANSACTION_TYPE = 'U')
BEGIN
IF EXISTS(
SELECT T0.Price FROM IGN1 T0
where IsNull(T0.Price, '0') = '0' and T0.DocEntry = @list_of_cols_val_tab_del)
BEGIN
SELECT @ERROR=1,@ERROR_MESSAGE='Please insert the price !'
END
end
-- Select the return values
select @error, @error_message
endHi Rathna,
Just put the SP like this, without the -- before the IF. A -- marks the line as a command therefore you need to uncomment and it will work.
IF @OBJECT_TYPE = '59' AND (@TRANSACTION_TYPE = 'A' or @TRANSACTION_TYPE = 'U')
BEGIN
IF EXISTS(
SELECT T0.Price FROM IGN1 T0
where IsNull(T0.Price, '0') = '0' and T0.DocEntry = @list_of_cols_val_tab_del)
BEGIN
SELECT @ERROR=1,@ERROR_MESSAGE='Please insert the price !'
END
end
Hope it helps -
Server must specify table in Query Manager
Dear All,
I am using below query to generate information related to GRPO but getting error
'microsoft sql server native client sql server must specify table to select from microsoft sql server native client Swei could not be prepared'
SELECT Distinct T7.DOCNUM AS ' INVOICE No.',T7.DocDate as 'Invoice Date',T7.TaxDate as 'Document Date',T7.DocDueDate,'PO','DocDate',T7.CardCode as 'Vendor Code', T7.CARDNAME as 'Vendor Name',
T7.NUMATCARD as 'Vendor Invoice No.',
T7.SHIPTOCODE as 'Ship To Code',T6.ITEMCODE,T6.DSCRIPTION,T6.Width1, cast(T15.UserText as VarChar) as 'Item Remarks',
T6.QUANTITY,T6.WhsCode as 'Wh Name',T6.UnitMsr as 'UoM',T6.PRICE as 'Basic Price',T6.LineTotal as 'Basic Amount',
T10.[TransCat] as 'Purchase Type',T6.U_InvoiceNo 'Vendor Invoice No',T6.U_InvDate 'Vendor Invoice Date',
T7.Address As 'Bill To Address',T7.Address2 As 'Ship To Address',T7.U_CST,T7.U_VAT,T7.U_PAN,T12.[U_CreditRatPayer], T12.[U_CreditRatCheq], T12.[U_CreditRatPoints], T12.[U_DiscApp] ,
T10.State as 'Vendor State',
T15.[U_ItemType], T15.[U_Pattern], T15.[U_PurchaseType], T15.[U_Origin], T15.[U_ProductRange], T15.[U_NSD], T15.[U_Segment], T15.[U_SpeedRating],
T15.[U_Brand], T15.[U_Category], T15.[U_CompoType], T15.[U_OTHBCategory], T15.[U_WidthIN], T15.[U_WidthCM], T15.[U_RimWidthIN],
T15.[U_AspectRate], T15.[U_Plyrating], T15.[U_CountryMmanu], T15.[U_ProductType], T15.[U_Radiatyre], T15.[U_Loadindex], T15.[U_CategoryFTI], T15.[U_LoadindexFTI]
FROM
dbo.PDN1 T6 inner join OPDN T7 ON T6.DocEntry = T7.DocEntry LEFT JOIN
dbo.OITM T15 ON T15.ItemCode = T6.ItemCode LEFT JOIN
dbo.OSLP T8 on T7.SLPCode = T8.SlpCode LEFT JOIN
dbo.OHEM T9 on T7.OwnerCode = T9.empID LEFT JOIN
dbo.PDN12 T10 on T7.Docentry = T10.DocEntry LEFT JOIN
dbo.OCRD T12 on T7.CardCode = T12.CardCode
Where T6.TargetType <> '19' and T15.U_ItemType = 'Tyre' and T7.DocDate >= '[%0]' and T7.DocDate <= '[%1]'
We tried to declare variable but error still appears.
Thanks
DeepakTry This
/* select docdate from OPDN t1 */
DECLARE @d1 AS DATETIME
DECLARE @d2 AS DATETIME
SET @d1 =/* t1.docdate */ '[%0]'
SET @d2 =/* t1.docdate */ '[%1]'
SELECT DISTINCT T7.DOCNUM AS ' INVOICE No.',
T7.DocDate AS 'Invoice Date',
T7.TaxDate AS 'Document Date',
T7.DocDueDate,
'PO',
'DocDate',
T7.CardCode AS 'Vendor Code',
T7.CARDNAME AS 'Vendor Name',
T7.NUMATCARD AS 'Vendor Invoice No.',
T7.SHIPTOCODE AS 'Ship To Code',
T6.ITEMCODE,
T6.DSCRIPTION,
T6.Width1,
CAST(T15.UserText AS VARCHAR) AS 'Item Remarks',
T6.QUANTITY,
T6.WhsCode AS 'Wh Name',
T6.UnitMsr AS 'UoM',
T6.PRICE AS 'Basic Price',
T6.LineTotal AS 'Basic Amount',
T10.[TransCat] AS 'Purchase Type',
T6.U_InvoiceNo 'Vendor Invoice No',
T6.U_InvDate 'Vendor Invoice Date',
SELECT DISTINCT ISNULL(SUM(PDN4.taxsum), 0)
FROM PDN4
WHERE PDN4.statype = 10
AND PDN4.docentry = T7.Docentry
AND PDN4.linenum = T6.Linenum
) BED,
SELECT DISTINCT ISNULL(SUM(PDN4.taxsum), 0)
FROM PDN4
WHERE PDN4.statype = 11
AND PDN4.docentry = T7.Docentry
AND PDN4.linenum = T6.Linenum
) Cess,
SELECT DISTINCT ISNULL(SUM(PDN4.taxsum), 0)
FROM PDN4
WHERE PDN4.statype = 12
AND PDN4.docentry = T7.Docentry
AND PDN4.linenum = T6.Linenum
) HeCess,
SELECT DISTINCT ISNULL(SUM(PDN4.taxsum), 0)
FROM PDN4
WHERE PDN4.statype = 5
AND PDN4.docentry = T7.Docentry
AND PDN4.linenum = T6.Linenum
) ServiceTax,
SELECT DISTINCT ISNULL(SUM(PDN4.taxsum), 0)
FROM PDN4
WHERE PDN4.statype = 6
AND PDN4.docentry = T7.Docentry
AND PDN4.linenum = T6.Linenum
) ServiceCess,
SELECT DISTINCT ISNULL(SUM(PDN4.taxsum), 0)
FROM PDN4
WHERE PDN4.statype = -10
AND PDN4.docentry = T7.Docentry
AND PDN4.linenum = T6.Linenum
) ServiceHeCess,
SELECT DISTINCT ISNULL(SUM(PDN4.taxsum), 0)
FROM PDN4
WHERE PDN4.statype = 1
AND PDN4.docentry = T7.Docentry
AND PDN4.linenum = T6.Linenum
) VAT,
SELECT DISTINCT ISNULL(SUM(PDN4.taxsum), 0)
FROM PDN4
WHERE PDN4.statype = 7
AND PDN4.docentry = T7.Docentry
AND PDN4.linenum = T6.Linenum
) Surcharge,
SELECT DISTINCT ISNULL(SUM(PDN4.taxsum), 0)
FROM PDN4
WHERE PDN4.statype = 8
AND PDN4.docentry = T7.Docentry
AND PDN4.linenum = T6.Linenum
) EntryTax,
SELECT DISTINCT ISNULL(SUM(PDN4.taxsum), 0)
FROM PDN4
WHERE PDN4.statype = 4
AND PDN4.docentry = T7.Docentry
AND PDN4.linenum = T6.Linenum
) CST,
STR(
SELECT (PDN3.[LineTotal] * T6.[LineTotal]) / (T7.[Doctotal] -T7.[TotalExpns] -T6.[VatSum])
FROM PDN3
WHERE PDN3.docentry = T7.Docentry
AND PDN3. ExpnsCode = '1'
19,
2
) AS 'Freight',
T7.[WTSum] * T6.[LineTotal] / (T7.[Doctotal] -T7.[TotalExpns] -T7.[VatSum] + T7.[WTSum]) AS
'TDS',
T7.DocTotal * T6.[LineTotal] / (T7.[Doctotal] -T7.[TotalExpns] -T7.[VatSum] + T7.[WTSum]) AS
'DocTotal',
T6.Freetxt AS ' Text',
T8.[SlpName],
(T9.[firstName] + ' ' + T9.[lastName]) AS 'Owner',
T7.Address AS 'Bill To Address',
T7.Address2 AS 'Ship To Address',
T7.U_CST,
T7.U_VAT,
T7.U_PAN,
T12.[U_CreditRatPayer],
T12.[U_CreditRatCheq],
T12.[U_CreditRatPoints],
T12.[U_DiscApp],
T10.State AS 'Vendor State',
T15.[U_ItemType],
T15.[U_Pattern],
T15.[U_PurchaseType],
T15.[U_Origin],
T15.[U_ProductRange],
T15.[U_NSD],
T15.[U_Segment],
T15.[U_SpeedRating],
T15.[U_Brand],
T15.[U_Category],
T15.[U_CompoType],
T15.[U_OTHBCategory],
T15.[U_WidthIN],
T15.[U_WidthCM],
T15.[U_RimWidthIN],
T15.[U_AspectRate],
T15.[U_Plyrating],
T15.[U_CountryMmanu],
T15.[U_ProductType],
T15.[U_Radiatyre],
T15.[U_Loadindex],
T15.[U_CategoryFTI],
T15.[U_LoadindexFTI]
FROM dbo.PDN1 T6
INNER JOIN OPDN T7
ON T6.DocEntry = T7.DocEntry
LEFT JOIN dbo.OITM T15
ON T15.ItemCode = T6.ItemCode
LEFT JOIN dbo.OSLP T8
ON T7.SLPCode = T8.SlpCode
LEFT JOIN dbo.OHEM T9
ON T7.OwnerCode = T9.empID
LEFT JOIN dbo.PDN12 T10
ON T7.Docentry = T10.DocEntry
LEFT JOIN dbo.OCRD T12
ON T7.CardCode = T12.CardCode
WHERE T6.TargetType <> '19'
AND T15.U_ItemType = 'Tyre'
AND T7.DocDate >= @d1
AND T7.Docdate <= @d2 -
Must specift the table to select from error in query generator.
SELECT OPCH.CardCode,OPCH.CardName, DateName(month,OPCH.TaxDate) + '-' + DateName(year,OPCH.TaxDate) As [Year],OPCH.TransId as [JE Ref],'IN' As [DocType]
,OPCH.DocEntry As [Base DocEntry],OPCH.WTSUM As [Recieved Amount],((OPCH.WTSUM/110.3) * 100 ) As [Invoice Amount],((OPCH.WTSUM/110.3) * 100 * 0.1) As [Service Tax]
,((OPCH.WTSUM/110.3) * 100 * 0.002) As [Edu.Cess],((OPCH.WTSUM/110.3) * 100 * 0.001) As [S.H.Cess]
,((OPCH.WTSUM/110.3) * 100 * 0.1) + ((OPCH.WTSUM/110.3) * 100 * 0.002) + ((OPCH.WTSUM/110.3) * 100 * 0.001) As [Total Service Tax]
FROM OPCH,PCH1
WHERE OPCH.DocEntry = PCH1.DocEntry
AND OPCH.WTSUM > 0
And PCH1.TargetType <> '19'
AND OPCH.DocDate >= [%0]
AND OPCH.DocDate <= [%1]
When i try to run this query in query generator system gives me error msg as "Must specify table to select from" if i remove the last two lines
" AND OPCH.DocDate >= [%0]
AND OPCH.DocDate <= [%1] "
it works fine in the query generator.
can any one help in this regards,
thanks,
praveenHai Praveen!
This problem is because of [%0] in query.
Declare @FromDate as datetime
Declare @ToDate as datetime
set @FromDate = (select min(opch.docdate) from opch where opch.docdate >= '[%0]')
set @ToDate = (select max(opch.docdate) from opch where opch.docdate <= '[%1]')
Use this query in first lines of ur query and write your query.
SELECT OPCH.CardCode,OPCH.CardName, DateName(month,OPCH.TaxDate) + '-' + DateName(year,OPCH.TaxDate) As Year,OPCH.TransId as JE Ref,'IN' As DocType
,OPCH.DocEntry As Base DocEntry,OPCH.WTSUM As Recieved Amount,((OPCH.WTSUM/110.3) * 100 ) As Invoice Amount,((OPCH.WTSUM/110.3) * 100 * 0.1) As Service Tax
,((OPCH.WTSUM/110.3) * 100 * 0.002) As http://Edu.Cess,((OPCH.WTSUM/110.3) * 100 * 0.001) As http://S.H.Cess
,((OPCH.WTSUM/110.3) * 100 * 0.1) + ((OPCH.WTSUM/110.3) * 100 * 0.002) + ((OPCH.WTSUM/110.3) * 100 * 0.001) As Total Service Tax
FROM OPCH,PCH1
WHERE OPCH.DocEntry = PCH1.DocEntry
AND OPCH.WTSUM > 0
And PCH1.TargetType '19'
AND OPCH.DocDate >= @FromDate
AND OPCH.DocDate <= @ToDate
Regards,
Thanga Raj.K -
ODBC connection failed (SQL Server Native Client)
Dear ..
I tried to connect to ODBC with SQL Server Native Client 11.0.
It successfully connected in SQL mgmt studio : (LocalDB)\AAA
but when I tried to connect to ODBC, it's failed like below..
[Microsoft][SQL Server Native Client 11.0][SQL Server]Login failed for user 'KKIKKI\Jinsu'.
[Microsoft][SQL Server Native Client 11.0][SQL Server]Cannot open database "MAPDB" requested by the login. The login failed.
test failed.
How to initialize all of my SQL Native Client and ODBC configuration?
I tried to remove all SQL application, but it's same situation.. Please help..
jinsuhttps://www.connectionstrings.com/sql-server-native-client-11-0-odbc-driver/
T-SQL Articles
T-SQL e-book by TechNet Wiki Community
T-SQL blog -
Problem Description:
ODBC functions SQLExecDirectW and SQLExecute functions return error:”DIAG [22001] [Microsoft][SQL Server Native Client 10.0]String data, right
truncation (0) “. When we enable tracing in the ODBC administrator, in the SQL.log we see that values for the arguments: ColumnSize, BufferLength, and StrLen_or_IndPtr of ODBC function SQLBindParameter are not being displayed.
Environment Used:
OS: Microsoft Windows Server 2003 R2 Standard x64 Edition.
Complier: Microsoft Visual Studio 2008 SP1 for x64.
Database: Microsoft SQL Server 2008
MDAC: Microsoft Data Access Components SDK 2.8
Note: This problem is seen only in our 64bit application. However, in 32bit
SQLExecDirectW and SQLExecute functions return successfully.
As we could not find the values of 6<sup>th</sup>, 9<sup>th</sup> and 10<sup>th</sup> arguments(ColumnSize,
BufferLength, and StrLen_or_IndPtr) passed to
SQLBindParameter in the ODBC traces for 64bit, we are not sure whether the values for the above mentioned arguments are received correctly by SQLBindParameter or not. This information would help us to debug further. So, could you please let us know why
these values are not displayed.
1)Here is the extract of the SQL.log file for 32bit where the values for SQLULEN , SQLLEN and SQLLEN* are displayed properly:
PR0CNFG 1028-15f0 ENTER SQLBindParameter
HSTMT 0x006FBDD8
UWORD 1
SWORD 1 <SQL_PARAM_INPUT>
SWORD -8 <SQL_C_WCHAR>
SWORD -9 <SQL_WVARCHAR>
SQLULEN 23
SWORD 0
PTR 0x0595EBBA
SQLLEN 46
SQLLEN * 0x05A5FB00
2)Here is the extract of the SQL.log file for 64bit where the values for SQLULEN , SQLLEN are not displayed properly and
SQLExecDirectW function return error:”DIAG
[22001] [Microsoft][SQL Server Native Client 10.0]String data, right truncation (0) “. :
PR0CNFG a78-fe4 ENTER SQLBindParameter
HSTMT 000000000431D2F0
UWORD 1
SWORD 1 <SQL_PARAM_INPUT>
SWORD -8 <SQL_C_WCHAR>
SWORD -9 <SQL_WVARCHAR>
SQLULEN SQLULEN SWORD 0
PTR 0x0000000005364EFA
SQLLEN SQLLEN
SQLLEN * SQLLEN *
PR0CNFG a78-fe4 EXIT SQLBindParameter with return code 0 (SQL_SUCCESS)
HSTMT 000000000431D2F0
UWORD 1
SWORD 1 <SQL_PARAM_INPUT>
SWORD -8 <SQL_C_WCHAR>
SWORD -9 <SQL_WVARCHAR>
SQLULEN SQLULEN SWORD 0
PTR 0x0000000005364EFA
SQLLEN SQLLEN SQLLEN *Hi Nalsr,
From my research, I found:
"[Microsoft][ODBC SQL Server Driver]String
data right truncation" error may be returned from a call to
SQLBindParameter if the size of the string parameter being used is greater than the size of the column being compared to. In other words if the
string size of the <expression> to the left of the <comparison_operator> is less than the
string size of the <expression> to the
right, ODBC may return this error.
The resolution is to make the string size of the <expression> to the
right of the <comparison_operator> less than or equal to the
string size of the <expression> on the left.
It is difficult to track down this type of problem when third party development applications are being used. ODBC Trace can be used to help determine if this problem is occuring.
Here is an example where the customer has submitted a query "select count(*) from type1 where type1 = ?", type1 is varchar(5) and the
data type being passed by the application is char[9].
Here is the relevant portion of the trace. The following information from the "exit" of SQLDescribeParam
SWORD * 0x0095e898 (12)
UDWORD * 0x0095e880 (5)
Maps to the following with the actual value in parenthesis - SQL_VARCHAR Size 5:
SQLSMALLINT *DataTypePtr
SQLUINTEGER *ParameterSizePtr
The "exit" value from SQLBindParameter provides the following
information:
SWORD 1 <SQL_PARAM_INPUT>
SWORD 1 <SQL_C_CHAR>
SQL Data Type SWORD 12 <SQL_VARCHAR>
Parameter Size UDWORD 5
SWORD 0
Value PTR 0x0181c188
Value Buffer Size SDWORD 5
String Length SDWORD * 0x0181c103 (9)
The string length parameter is the length of the
string being bound to the parameter, in this instance there is a size mismatch which results in the SQLError and the SQLErrorW with the message "[Microsoft][ODBC SQL Server
Driver]String data
right truncation" .
Hope this could be helpful.
Best regards,
Halin Huang -
Hi
i am getting these errors in sharepoint server event viewer, and when i see the sql server the log files disk is full memory only some mbs left out of 1 TB
Log Name: Application
Source: Microsoft-SharePoint Products-SharePoint Server Search
Date: 7/12/2014 9:56:04 PM
Event ID: 57
Task Category: Search service
Level: Warning
Keywords:
User: XYZ\svc-mc-sps3eServsear
Computer: SPFIND01.xyz.gov.local
Description:
A database error occurred. Source: Microsoft SQL Server Native Client 10.0 Code: 1205 occurred 1 time(s) Description: Transaction (Process ID 193) was deadlocked on lock
resources with another process and has been chosen as the deadlock victim. Rerun the transaction.
Context: Application 'XYZSP_SearchApp'
Event Xml:
<Event xmlns="http://schemas.microsoft.com/win/2004/08/events/event">
<System>
<Provider Name="Microsoft-SharePoint Products-SharePoint Server Search" Guid="{C8263AFE-83A5-448C-878C-1E5F5D1C4252}" />
<EventID>57</EventID>
<Version>14</Version>
<Level>3</Level>
<Task>136</Task>
<Opcode>0</Opcode>
<Keywords>0x4000000000000000</Keywords>
<TimeCreated SystemTime="2014-07-12T18:56:04.665684900Z" />
<EventRecordID>225666</EventRecordID>
<Correlation />
<Execution ProcessID="3408" ThreadID="2932" />
<Channel>Application</Channel>
<Computer>SPFIND01.xyz.gov.local</Computer>
<Security UserID="S-1-5-21-1537596049-1164153464-4201862467-47315" />
</System>
<EventData>
<Data Name="string0">Microsoft SQL Server Native Client 10.0</Data>
<Data Name="string1">1205</Data>
<Data Name="string2">1</Data>
<Data Name="string3">Transaction (Process ID 193) was deadlocked on lock resources with another process and has been chosen as the deadlock
victim. Rerun the transaction.</Data>
<Data Name="string4">
Context: Application 'XYZSP_SearchApp'</Data>
</EventData>
</Event>
A database error occurred. Source: Microsoft SQL Server Native Client 10.0 Code: 9002 occurred 1 time(s) Description: The transaction log for database 'tempdb' is full due to 'ACTIVE_TRANSACTION'.
Context: Application 'XYZSP_SearchApp'
adilIf you've run out of disk space for your SQL databases then of course you'll get errors. Fix SQL then look to see if you're still getting errors.
-
Sqlcmd: Error: Microsoft SQL Server Native Client 10.0
Hi All .need help ..
When I am running this from cmd on my sql 2008 database server:
sqlcmd -U sa -S mymachinen_name\MSSQLSERVER , MSSQLSERVER is my instance name ,
I get prompt for password and after that I get this:
Password: HResult 0x57, Level 16, State 1
SQL Server Network Interfaces: Connection string is not valid [87].
Sqlcmd: Error: Microsoft SQL Server Native Client 10.0 : A network-related or in
stance-specific error has occurred while establishing a connection to SQL Server
. Server is not found or not accessible. Check if instance name is correct and i
f SQL Server is configured to allow remote connections. For more information see
SQL Server Books Online..
Sqlcmd: Error: Microsoft SQL Server Native Client 10.0 : Login timeout expired.
I have my sqserver browser service started and also I can login through managemnet studio with windows authentication.
Also found this :
http://support.microsoft.com/kb/905618 , but this is for MS Server 2005/2000.
Can you guys please help me.
RegardsHello,
Try the following commands from your computer and
from the local server:
SQLCMD -E -S mymachinen_name\MSSQLSERVER
SQLCMD -E -S mymachinen_name
Use SQL Server Management Studio and connect
to the SQL server with the SA account
and password. If this does not work,
your SA account is disabled or the SQL
server is configured for Windows authentication.
If MSSQLSERVER is the default instance
of your SQL Server, do not use it in your
command line SQLCMD
Check on your SQL server
remote connections are enabled
If you are using TCP / IP, add an inbound
TCP exception in the firewall of your SQL
server on port used by your SQL Server instance
+ an inbound UDP 1434
exception for the SQL Server Browser service
Regards
Charlie Dancoisne - Independent Consultant & Trainer (Please take a moment to "Vote as Helpful" and/or "Mark as Answer", where applicable. This helps the community, keeps the forums tidy, and recognises useful contributions. Thanks!) -
CR 2008 SP3 FP 3.4 does not provide SQL Server Native Client 10.0
One of my clients is running Crystal Reports 2008 SP3 Fix Pack 3.4 on a Windows 2008 R2 server and is running MS SQL 2008 (not R2) on a separate Windows 2008 R2 server. This was installed to correct printer issues. As expected, they started getting errors on some that use dates in the record selection formula.
I informed them that we needed to change the data connection driver from "Microsoft OLE DB Provider for SQL Server' to "SQL Server Native Client 10.0". When they go in to create a new data connection the OLE DB (ADO) Provider list does not list "SQL Server Native Client 10.0" as an option.
As I understand it from another thread on this site, this OLE DB client version is required for CR 2008 to properly interface with SQL 2008 and that it should be available after installing FP 3.2 or 3.3. I made sure that they installed all fix packs in their released order.
Can anyone shed some light on this for me?Hello,
Actually there is:
{tblCaseData.CloseCodeID} = 2
and {tblCaseData.CaseSplitTrusteeCode} 'A'
and {%sql_Adj341Date} >= {?pf_BeginDate}
and {%sql_Adj341Date} < DateAdd ( 'd', 1, {?pf_EndDate} )
and {%sql_CountACH} = 0
and {%sql_CountNameIDParties} = 0
and {%sql_CourtWageDir} = 0
{%sql_Adj341Date} >= {?pf_BeginDate} and {%sql_Adj341Date} < DateAdd ( 'd', 1, {?pf_EndDate} ) is the result of NOT statement.
Try something like this:
{tblCaseData.CloseCodeID} = 2
and {tblCaseData.CaseSplitTrusteeCode} 'A'
and ({%sql_Adj341Date} >= {?pf_BeginDate}
and {%sql_Adj341Date} < DateAdd ( 'd', 1, {?pf_EndDate} ))
and {%sql_CountACH} = 0
and {%sql_CountNameIDParties} = 0
and {%sql_CourtWageDir} = 0
I added AND/OR/NOT etc. logic to:
and ({%sql_Adj341Date} >= {?pf_BeginDate}
and {%sql_Adj341Date} < DateAdd ( 'd', 1, {?pf_EndDate} ))
You'll have to figure out what the correct bracketing should be for your data and what you want to get out of it. Possibly moving the date part to the end of the selection formula will "fix" this.
Thank you
Don
Maybe you are looking for
-
How can transfer data from a dialog to another panel?
Will anyone help me?Thanks. In our project,When the user need to fill some data into the textfield in a panel,he can simplify this action by click a button,when the button is clicked,then a dialog which contains a table of all the imformation of all
-
Unable to interact with Flash content when running Firefox with restricted user
When running Firefox with limited Windows user on Windows XP the Flash elements are displayed, the content that is set to auto-play does so even, but the flash area doesn't receive any mouse input: e.g. when I right click in the area instead of the f
-
Error when compile SimpleBrowser.java (demo files in jdic)
i got this error ... *** Jtrace: MyFocusListener: focusGained *** Jtrace: connected *** Jtrace: Got event: type = 0 instance = 0 *** Jtrace: send data to socket: 0,0, *** Jtrace: Got event: type = 1 instance = 0 *** Jtrace: Can't get native window ha
-
What program is used to use Flash based web programs
I have a Member who is using a MAC Computer and trying to Access a Internet order program which uses Flash Player, How can they Access this site?
-
Mls qos trust dscp??? is setting my DSCP values to zero!?
Hi, I was just doing some testing to ensure that the command 'mls qos trust dscp' is working on my 6509 switches before rolling out QoS. Before adding any configuration I could see using wireshark that traffic from my Avaya 9608 handset was coming th